Gruffydd ap Llywelyn

Gruffydd ap Llywelyn (c. 1010 – 5 August 1063) was King of Gwynedd and Powys from 1039 and, after asserting his control over the entire country, claimed the title King of Wales from 1055 until his death in 1063. He was the son of Llywelyn ap Seisyll king of Gwynedd and Angharad daughter of Maredudd ab Owain, king of Deheubarth, and the great-great-grandson of Hywel Dda. Gruffydd was the first and only Welsh king to unite all of Wales albeit for a brief period. After his death, Wales was again divided into separate kingdoms.

Genealogy and early life
Gruffydd was the son of Llywelyn ap Seisyll, who had been able to rule both Kingdom of Gwynedd and Kingdom of Powys, and of Angharad ferch Maredudd. On Llywelyn's death in 1023, a member of the House of Aberffraw, Iago ab Idwal ap Meurig, became ruler of Gwynedd and began his rise to power in Powys.

King of Gwynedd and Powys (1039–1055)
In 1039, Iago, king of kingdom of Gwynedd, was killed (supposedly by his own men), his son Cynan forced into exile in Dublin, and Gruffydd was made King. Soon after gaining power, he surprised a Mercian army at Rhyd y Groes near Welshpool and defeated it, killing Edwin, brother of Leofric, Earl of Mercia. He then attacked Dyfed, which his father had ruled but was now under Hywel ab Edwin. Gruffydd again defeated Hywel in the Battle of Pencader in 1041 (halfway between Carmarthen and Lampeter but didn't win entirely until 1042 at "Pwlldyfach" (near Carmarthen) and carried off Hywel's wife. Gruffydd seems to have been able to drive Hywel (and his Irish fleet of "Black Gentiles / Pagans") out of the south, for in 1044 Hywel is again recorded returning to River Towy with a fleet from Ireland, Gruffydd, however, defeated and killed Hywel.

Gruffydd ap Rhydderch of Kingdom of Gwent was able to expel Gruffydd ap Llywelyn from Deheubarth in 1047 and became king of Deheubarth himself. Afterwards the nobles of Ystrad Tywi had attacked and killed 140 of Gruffydd ap Llywelyn's household guards, Gruffydd exacted his revenge in Towy and Dyfed. Gruffydd ap Llywelyn was active on the Welsh border in 1052 when he attacked Herefordshire with an army consisting of a fleet of 18 ships from Ireland, they defeated a mixed force of Normans and Anglo-Saxons in the Battle of Leominster.

Ruler of all Wales (1055–1063)


According to Brut y Tywysogion, Sweyn Godwinson was called in to help Gruffydd's brother Rhys against Gruffydd ap Rhydderch in 1045 to keep hold of Deheubarth. Gruffydd raided Leominster in 1052, which was the Battle of Llanllieni, the Welsh fought Normans and Anglo-Saxons.

In 1055 Gruffydd ap Llywelyn killed his rival Gruffydd ap Rhydderch in battle and recaptured Deheubarth. Gruffydd allied himself with Ælfgar, son of Leofric, Earl of Mercia, who had been deprived of his earldom of East Anglia by Harold Godwinson and his brothers. They marched on Hereford and were opposed by a force led by the Earl of Hereford, Ralph the Timid, then set Hereford on fire. This force was mounted and armed in the Norman fashion, but on 24 October 1055 Gruffydd and Ælfgar defeated it. They then sacked the city and destroyed its motte-and-bailey castle. Earl Harold was given the task of counter-attacking, but Gruffydd and Ælfgar had retreated to South Wales whilst Harold ventured no further than Hereford. He seems here to have built a fortification at Longtown in Herefordshire before refortifying Hereford. Shortly afterwards, Ælfgar was restored to his earldom and a peace treaty concluded.

Around this time Gruffydd was also able to seize Morgannwg and Gwent, along with extensive territories along the border with England.

Historian John Davies stated that Gruffydd was:


 * "The only Welsh king ever to rule over the entire territory of Wales... Thus, from about 1057 until his death in 1063, the whole of Wales recognised the kingship of Gruffudd ap Llywelyn. For about seven brief years, Wales was one, under one ruler, a feat with neither precedent nor successor".

During this time, between 1053 and 1063, Wales lacked any internal strife and was at peace. The later Brut y Tywysogion described him as being "the head and shield of the Britons". John of Worcester referred to him, several decades later, as Rex Walensium, King of the Welsh.

Death and aftermath
Gruffydd reached an agreement with Edward the Confessor, but the death of his ally Ælfgar in 1062 left him more vulnerable. In late 1062 Harold Godwinson obtained the English king's approval for a surprise attack on Gruffydd's court at Rhuddlan. Gruffydd was nearly captured, but was warned in time to escape out to sea in one of his ships, though his other ships were destroyed. In the spring of 1063 Harold's brother Tostig Godwinson led an army into North Wales while Harold led the fleet first to south Wales and then north to meet his brother's army. Gruffydd was forced to take refuge in Snowdonia, where he met his death. Gruffydd's head and the figurehead of his ship were sent to Harold. The Ulster Chronicle states that he was killed in 1064 by Cynan, whose father Iago had been put to death by Gruffydd in 1039. Gruffydd had probably made enemies in the course of uniting Wales under his rule. According to Walter Map, Gruffydd said of this:


 * "Speak not of killing; I but blunt the horns of the offspring of Wales lest they should injure their dam".

Following Gruffydd's death, Harold married his widow Ealdgyth, who was to be widowed again three years later. Gruffydd's realm was divided again into the traditional kingdoms. Bleddyn ap Cynfyn and his brother Rhiwallon came to an agreement with Harold and were given the rule of Gwynedd and Powys. Thus when Harold was defeated and killed at the Battle of Hastings in 1066, the Normans reaching the borders of Wales were confronted by the traditional kingdoms rather than a single king. Gruffydd left two sons who in 1069 challenged Bleddyn and Rhiwallon at the Battle of Mechain in an attempt to win back part of their father's kingdom. However, they were defeated, one being killed and the other dying of exposure after the battle.

Family
Gruffydd married Ealdgyth, daughter of Earl Ælfgar of Mercia after he abducted, and marriage to, the wife, name unknown, of Hywel ab Edwin in 1041. Gruffydd had at least three children: two sons called Maredudd and Idwal, both of whom died at the Battle of Mechain in 1069, and a daughter, Nest ferch Gruffydd, who married Osbern fitzRichard of Richard's Castle. Their daughter Nest ferch Osbern (Nesta of Hereford) married Bernard de Neufmarché. Gruffydd may have had another son, Owain ap Gruffudd, who died in 1059.