The area now known as Wales has been inhabited by modern humans for at least 29,000 years, though continuous human habitation dates from the period after the last Ice age. Wales has many remains from the Neolithic period (mainly chambered tombs), as well as from the Bronze Age and Iron Age. The written history of Wales begins with the arrival of the Romans, who launched their first campaign against the Deceangli in north-east Wales in 48. Two of the larger tribes, the Silures and the Ordovices, resisted Roman rule for some years, with the Ordovices only being finally subdued in 79. Wales became part of the Roman province of Brittania, and remained under Roman rule until the legions were withdrawn in about 400. During the next few centuries kingdoms such as Gwynedd and Powys were formed and Wales became Christian.
During the early mediaeval period Wales was divided into a number of kingdoms, though some rulers were able to combine several kingdoms to extend their rule to much of Wales and Gruffydd ap Llywelyn in the mid 11th century controlled all of Wales and some areas in England for a period. These centuries were marked by struggles against English kingdoms such as Mercia, then against the united English kingdom and finally against the Normans, who arrived on the borders of Wales around 1067. Warfare continued for over two centuries until the death of Llywelyn the Last in 1282 led to the annexation of Wales to the kingdom of England. Owain Glyndŵr led a rebellion in the early 15th century and kept control of Wales for a few years before the English crown reimposed its authority. In the 16th century legislation was passed aimed at fully incorporating Wales into England.
The eighteenth century saw the beginnings of two changes which would greatly affect Wales, the Industrial Revolution and the Methodist revival. During the 19th century south-east Wales in particular experienced rapid industrialization and a dramatic rise in population. These areas were Welsh-speaking initially but became increasingly anglicized in speech later in the century. The 19th century also saw Wales become predominantly Nonconformist in religion. In the 20th century the period after the Second World War saw the beginnings of a long decline in the coal and iron industries and in politics saw the Labour party replace the Liberal party as the dominant force. In the second half of the century Plaid Cymru won its first seat at Westminster in 1966 and devolution became an item on the political agenda. A referendum on devolution in 1979 resulted in a "no" vote, but the issue reappeared towards the end of the century. A second referendum in 1997 resulted in a "yes" vote by a narrow margin and led to the Welsh Assembly being established in Cardiff.
The results of the 2001 Census showed an increase in the number of Welsh speakers to 21% of the population aged 3 and over, compared with 18.7% in 1991 and 19.0% in 1981. This compares with a pattern of steady decline indicated by census results during the 20th century.
In Cardiff the Millennium Stadium, opened in 1999, was followed by the Wales Millennium Centre opened in 2004 as a centre for cultural events, notably opera. The new Welsh Assembly building, to be known as the Senedd, was completed in February 2006 and officially opened on St. David's Day that year.
In 2006 the Government of Wales Act gained Royal Assent meaning that from May 2007 the Queen would have the new legal identity of 'Her Majesty in Right of Wales' and would for the first time appoint Welsh Ministers and sign Welsh Orders in Council. It also made provision for a future referendum to ask the Welsh people if they would like the Welsh Assembly to gain the power to pass primary legislation e.g. to make true Welsh laws.