The siege of Harlech Castle (1461-14 August 1468) is famous as the longest siege in British history. For the last four years of the siege Harlech was the only place in England or Wales in Lancastrian hands, and acted as a base for their plots.
Although the siege is generally said to have lasted for seven years, for most of that time the castle wasn't actually under direct attack. It is perhaps more accurate to say that the castle was held against Edward IV for eight years and during that period came under intermittent attack, while also acting as a base for Lancastrian plots and even in 1468 for an invasion of Wales.
In June-July 1460 the Yorkists made a successful return from exile. On 10 July 1460 they defeated the Lancastrians at the battle of Northampton, captured Henry VI and took control of the government. This was a blow from which the Lancastrians never really recovered. Queen Margaret and the infant Prince Edward fled to Harlech Castle, where they briefly found safety. The Yorkists then attempted to seize the throne, triggering a wave of uprisings. The Lancastrians had a brief come-back, killing Richard of York at Wakefield (30 December 1460) and liberating Henry at the Second Battle of St. Albans (17 February 1461). They were stopped by York's son Edward, earl of March, who beat them into London, and then inflicted a crushing defeat on the Lancastrians at the battle of Towton (29 March 1461).
In the aftermath of the battle of Towton one of the few remaining centres of Lancastrian resistance was Wales, where Jasper Tudor, earl of Pembroke (Henry VI's half brother) put garrisons into Pembroke, Harlech, Carreg Cennen and Denbigh. Pembroke also had a small field army.
In July 1461 Edward IV decided to lead a campaign in Wales in person, and on 12 July he mobilized his artillery. Lord William Herbert and Walter Devereux, Lord Ferrers, were ordered to raise an army in the borders. Edward then decided not to lead the army himself and placed Lord Herbert in command.
Herbert conducted a highly successful campaign. On 30 September 1461 Pembroke Castle surrendered. Pembroke himself was believed to be in the north, and so Herbert followed him. The two sides clashed at Twt Hill, just outside Caernarvon, on 16 October 1461, and Herbert was victorious. Pembroke fled into exile in Ireland, leaving his castles to face sieges. Denbigh surrendered in January 1462 and Carreg Cennon was captured by Herbert's brother Richard in May 1462.
This only left Harlech Castle. In the fifteenth century Harlech still stood right on the coast, and could thus be supplied by ships landing at the foot of the rock it was built on (since then the coast had moved west and there is now a wide flat plain between the castle and the sea). Pembroke was able to get supplies into Harlech from his Irish base, and for the moment Edward decided that it wasn't worth the expense of trying to capture the place.
The garrison of Harlech was commanded by Davydd ap Ifan ap Einion, a veteran of the Hundred Years War. The castle also became a refuge for English Lancastrians, included Sir Richard Tunstall, a member of Henry VI's household. Tunstall was a remarkable figure who managed to survive the changing fortunes of the period with some skill. In 1463 he was in Harlech, but in early 1464 he moved to Northumberland where Henry VI still had a small court. This Lancastrian enclave was destroyed after the battle of Hexham, and Tunstall escorted Henry into relative safety in Lancashire. He then returned to Harlech, and was captured when the castle surrendered in 1468. He was pardoned in December 1468, but joined the 'readeption' government of Henry VI. He survived the battles that ended this Lancastrian restoration and was pardoned again in 1473. Eventually he found royal favour and entered the Order of the Garter under Richard III. Remarkably he survived Richard's fall and spent the last thirty years of his life as a loyal servant of the house of Tudor.
For most of the seven years of the siege Harlech acted as a base for Lancastrian plots, and a centre for rumours. The garrison was on the offensive for much of this period, raiding into Wales to get supplies and acting as an entry point for Lancastrian agents. Edward's decision not to attack may have saved money, but it frequently destabilised his regime.
Early in 1462 the garrison was involved in the Oxford plot. John de Vere, twelfth earl of Oxford, was discovered to have been writing to Margaret of Anjou. He may have been planning to lead a Lancastrian invasion, possibly with some troops landing at Harlech. Oxford was executed in February and the title passed to his second son, another John de Vere. The new earl of Oxford became a dedicated enemy of Edward IV and was involved in some of the last active fighting against him, capturing St. Michael's Mount in the autumn of 1473 and holding it into the following year.
In October 1467 Lord Herbert captured a messenger heading from Margaret of Anjou to Harlech. Under questioning the messenger attempted to implicate the earl of Warwick in these plots, and this almost caused an early breach between Edward and Warwick.
Edward attempted to end the siege peacefully. Early in the siege he offered the garrison a pardon if the surrendered, but promised that they would suffer attainder if they didn't (they and their descendents would lose their estates). In 1464 Parliament called on the garrison to surrender and Edward issued a deadline of 1 January 1465, but once again this was ignored.
The turning point came in 1468. In that year Edward announced that he was going to war against France, and Louis XI responded by funding an invasion led by Jasper Tudor, earl of Pembroke. Pembroke landed close to Harlech in June 1468 and raided into Wales. He captured Denbigh and held court in Henry VI's name. These exploits finally convinced Edward that Harlech would have to be captured.
Lord Herbert was issued with commissions of array to raise an army in the border counties, and probably gathered around 9,000 men. He split this army in two. One half, under his brother Richard, was to approach Harlech from the north, while Herbert attacked from the south. This involved both armies in difficult crossings of the mountains, and this part of the campaign was said to have been especially bloodthirsty. A Welsh tradition tells of a mother on Anglesey whose seven sons were all involved in the rebellion. She pleaded with Herbert to leave her one of the seven, but they were all executed.
Richard Herbert ran into Pembroke's army on his way to Harlech and scattered the Lancastrian field army. The brothers then united outside the castle, and began the final phase of the siege. This was finally a true siege, with the castle under bombardment and blockaded, at least by land. Neither side appears to have had any ships in the area during this fighting, so Pembroke had probably used his fleet to escape to safety in France.
Herbert offered terms to the garrison, but Davydd ap Einion is said to have replied that in his youth he held a Castle in France so long that all the old women in Wales talk of it, now he would hold Harlech so long that all the women in France would speak of it. If this quote comes from this period, then it was largely bluster, for the formal siege only lasted for about a month. Supplies were running short, and on 14 August 1468 the garrison surrendered on terms. David ap Eynon and most of the garrison were pardoned in December 1468, although a few of the English Lancastrians were executed in London. David ap Eynon disappears from history after the siege.
The fall of Harlech meant that all of England and Wales were finally under Yorkist control, but only a year later Warwick's revolts would lead to a renewal of the Wars of the Roses, triggering the phase that ended at Barnet at Tewkesbury in 1471. This time there would be no Lancastrian refuge in Wales and Edward IV was able to enjoy the rest of his reign in relative peace.