You can date almost every famous bit
The legend was assembled in public over four centuries and the additions are traceable. ARTHUR first appears as a war leader in Welsh sources with no round table, no wizard and no sword in a stone. Geoffrey of Monmouth turns him into a king in 1136 and supplies MERLIN and the sword Caliburn, which becomes EXCALIBUR.
The ROUNDTABLE arrives in 1155, invented by a Norman poet called Wace. LANCELOT and the love affair with GUINEVERE are added around 1180 by Chrétien de Troyes, in French, for a French court. The holy GRAIL turns up in the same author's unfinished last poem and is made Christian by later writers. Sir Thomas Malory then packages the lot in the 1400s, and that compilation is the version everyone means.
A French romance about an English king
This is the part that surprises people. A great deal of the Arthurian material most associated with England was written in French, in France, for aristocratic audiences who wanted stories about courtly love and personal honour rather than about defending Britain.
It shows in what the stories care about. The early Welsh Arthur fights battles. The later Arthur presides over a court while individual KNIGHTS ride off on a personal QUEST, fall in love unwisely, and worry about their own virtue. The GRAIL quest is explicitly a test of spiritual purity that most of the knights fail — GALAHAD succeeds because he is flawless, PERCIVAL nearly does, LANCELOT cannot because of the affair.
The sword in the stone and the sword in the lake are different swords
Malory has both and they are not the same object. The sword drawn from the STONE proves Arthur is the rightful king and is broken in a later fight. EXCALIBUR is then given to him by the Lady of the Lake, and must be thrown back into the water as he dies. Retellings collapse the two constantly, and that is how most people end up remembering Excalibur being pulled from a rock.
The scabbard matters more than the blade in the original, incidentally: while Arthur wears it he cannot bleed to death, and losing it is what makes his last battle fatal. It is a good example of how a detail can survive for centuries in the text and still get dropped by every film, because a magic sword is easier to draw than a magic belt.
A king who is not dead
The ending is the reason the legend keeps being reused. MORDRED and Arthur kill each other, and the body is carried to AVALON to be healed rather than buried — so the story does not close. Medieval writers called him the once and future king, and the idea that he will return when Britain needs him has been taken seriously at various points by people who should have known better.
That unfinished ending makes him endlessly available. Every century has rewritten CAMELOT as whatever it wanted: a model court, a doomed ideal, a political slogan. The grid holds the standard furniture — the WIZARD, the THRONE, a DRAGON, a JOUST, a SQUIRE hoping to be knighted — and our knights and castles page has the real version of the world these stories are set in, which was considerably muddier.