It’s a fun story!
Technically “London” didn’t become the capital until after the 16th century. What we now call “the City of London” was an entity of its own, the ancient square mile which Rome founded. And it still is in many ways. It was a power and money centre, even before the Norman Conquest.
Up through the Middle Ages, there was no fixed “capital” per se. The kings never stayed put in one place, they were moving about, and the capital was where the king was, not even where the government was. The government, at that time, were the king’s ministers who handled (get it?) the day-to-day jobs.
During the reign of the Wessex kings, Winchester was the closest thing to an English capital.
The first permanent residents of Winchester appear to have arrived in the Iron Age, sometime around 150BC, establishing both a hill fort and also a trading settlement on the western edge of the modern city. Winchester would remain the exclusive home of the Celtic Belgae tribe for the next two hundred years or so.
Shortly after the Romans landed at Richborough in Kent in AD 43, troops marched across the whole of southern Britain capturing Iron Age hill forts when necessary, and imposing Roman rule upon the local population.
Evidence suggests, however, that Winchester’s Belgae tribe may well have welcomed the invaders in with open arms. The Begae’s hill fort appears to have fallen into disrepair many years before the Romans arrived. Also, the invading Romans did not even feel threatened enough to establish a military fort in the area from which they could control revolting natives.
The Romans did, however, start to build their own ‘new town’ at Winchester. This Roman new town developed over the centuries of occupation to become the region’s capital, with streets laid out in a grid pattern to accommodate the splendid houses, shops, temples and public baths. By the 3rd century, the wooden town defences were replaced with stone walls, at which time Winchester extended to almost 150 acres, making it the fifth largest town in Roman Britain.
Along with other Romano-British towns, Winchester started to decline in importance around the 4th century. And things appear to have come to an almost abrupt end when in AD407, with their Empire crumbling, the last Roman legions were withdrawn from Britain.
For the rest of the fifth century and early sixth century, England entered what is now referred to as the Dark Ages. It was during these Dark Ages that the Anglo-Saxons became established in southern and eastern England.
From around AD430 a host of Germanic migrants arrived in England, with Jutes from the Jutland peninsula (modern Denmark), Angles from Angeln in southwest Jutland and Saxons from northwest Germany. Over the next hundred years or so, the invading kings and their armies established their kingdoms. Most of these kingdoms survive to this day, and are better known as the English counties; Kent (Jutes), East Anglia (east Angles), Sussex (south Saxons), Middlesex (middle Saxons) and Wessex (west Saxons).
It was the Saxons that referred to a Roman settlement as a ‘caester’, and so in west Saxon Wessex, Venta Belgarum became Venta Caester, before being changed to Wintancaester and eventually corrupted to Winchester.
From AD 597 the new Christian faith began to spread through southern England, and it was in the middle of the 7th century that the first Christian church, the Old Minster, was built within the Roman walls of Winchester. A few years later in 676, the Bishop of Wessex moved his seat to Winchester and as such the Old Minster became a cathedral.
Although born at Wantage in Berkshire, Winchester’s most famous son is Alfred ‘The Great’. Alfred (Aelfred) became ruler of the West Saxons after he and his brother defeated the Danish Vikings at the Battle of Ashdown. In 871 at the tender age of 21, Alfred was crowned King of Wessex and established Winchester as his capital.
So, back to London. The kings had no real power over London. Edward the Confessor, who was technically of the Wessex bloodline but spent his formative years across the Channel and didn’t have a sentimental attachment to Winchester, built an abbey in Westminster, which was west of London. He also constructed a palace for the seat of government. With these, he hoped to draw power and wealth from that citadel to the east protected by a massive wall.
Edward died in January 1066. In October, Duke William of Normandy arrived to take what he felt was his by right. After the Battle of Hastings, he travelled toward London, that centre of power. Not to London, mind you. Toward it.
He circled, burning his way around it. But he knew he couldn’t breach the wall. He made a deal with the London peeps that in exchange for recognising him as their king, they would retain their special privileges. This arrangement has been in place ever since.
Now, thanks to Edward the Confessor, there was a ready-made power base just to the west of London. William was duly crowned king in Westminster Abbey.
Over time, the Treasury was moved from Winchester, which became that historic city with one train station (London now has over 600 train and underground stations). Meanwhile, houses were built between the cities of Westminster and London, and a Greater London was formed, eventually swallowing up towns and villages in a 600 square mile area.
Note, though, that the City of London has no national government facilities in it, save the Bank of England, which is separate. Government (Parliament, Whitehall, Downing Street, etc…), the Palace, the national entities are in Westminster, but as that is in what became the megapolis of “London”, London is the capital.