The city's history can be traced to Roman times. A significant naval port for centuries, Portsmouth has the world's oldest dry dock and was England's first line of defence during the French invasion in 1545. Special Palmerston Forts were built in 1859 in anticipation of another invasion from continental Europe. By the early-19th century, Portsmouth was the most heavily fortified city in the world, and was considered "the world's greatest naval port" at the height of the British Empire throughout Pax Britannica. The world's first mass production line was set up in the city, making it the most industrialised site in the world. During the Second World War, the city was a pivotal embarkation point for the D-Day landings and was bombed extensively in the Portsmouth Blitz, which resulted in the deaths of 930 people. In 1982, a large proportion of the task force dispatched to liberate the Falkland Islands deployed from the city's naval base. Her Majesty's Yacht Britannia left the city to oversee the transfer of Hong Kong in 1997, which marked for many the end of the empire.
Portsmouth is one of the world's best known ports. HMNB Portsmouth is considered to be the home of the Royal Navy and is home to two-thirds of the UK's surface fleet. The city is home to some famous ships, including HMS Warrior, the Tudor carrack Mary Rose and Horatio Nelson's flagship, HMS Victory (the world's oldest naval ship still in commission). The former HMS Vernon naval shore establishment has been redeveloped as a retail park known as Gunwharf Quays. Portsmouth is among the few British cities with two cathedrals: the Anglican Cathedral of St Thomas and the Roman Catholic Cathedral of St John the Evangelist. The waterfront and Portsmouth Harbour are dominated by the Spinnaker Tower, one of the United Kingdom's tallest structures at 560 feet (170 m). Nearby Southsea is a seaside resort with a pier amusement park and medieval castle.
Portsmouth F.C., the city's professional football club, play their home games at Fratton Park. The city has several mainline railway stations that connect to London Waterloo amongst other lines in southern England. Portsmouth International Port is a commercial cruise ship and ferry port for international destinations. The port is the second busiest in the United Kingdom after Dover, handling around three million passengers a year. The city formerly had its own airport, Portsmouth Airport, until its closure in 1973. The University of Portsmouth enrols 23,000 students and is ranked among the world's best modern universities. Portsmouth is also the birthplace of author Charles Dickens and engineer Isambard Kingdom Brunel.
The Romans built Portus Adurni, a fort, at nearby Portchester in the late third century. The city's Old English name "Portesmuða" is derived from port, meaning a haven, and muða, the mouth of a large river or estuary. The Anglo-Saxon Chronicle has a warrior called Port and his two sons killing a noble Briton in Portsmouth in 501. Winston Churchill, in his A History of the English-Speaking Peoples, says that Port was a pirate and he founded Portsmouth in 501.
The south coast was vulnerable to Danish Viking invasions during the 8th and 9th centuries. In 787, it was assaulted and conquered by Danish pirates, and then during the reign of Æthelwulf, King of Wessex in 838, a Danish fleet landed between Portsmouth and Southampton and the surrounding area was plundered. In response, Æthelwulf sent Wulfherd and the governor of Dorsetshire to confront the Danes at Portsmouth, where most of their ships were docked. They were successful although Wulfherd was killed. In 1001, the Danes returned and pillaged Portsmouth and surrounding locations, threatening the English with extinction. The Danes were massacred by the survivors the following year and rebuilding began, although the town suffered further attacks until 1066.