Dinefwr Castle (sometimes anglicized as Dynevor) is a Welsh castle overlooking the River Tywi near the town of Llandeilo, Carmarthenshire, Wales. It lies on a ridge on the northern bank of the Tywi, with a steep drop of several hundred feet to the river. Dinefwr was the chief seat of the kingdom of Deheubarth. The castle is in the care of Cadw but lies within Dinefwr Park, which is owned by the National Trust. Visitors who wish to see the castle and are driving there, may pay admission for the car park, if not National Trust members. A separate fee is payable if you wish to visit Newton House. Alternatively, access is free to walkers from Llandeilo town nearby, and there is a small free car park near the castle, but it can only be reached by a rough track through the deer park.
Rhys ap Gruffydd also built the spectacular castle at Carreg Cennen, about four miles away to the south. It is not visible from Dynefwr, but Dryslwyn Castle can just be seen on a hill blocking the Tywi valley to the south-west. Rhys also founded two religious houses during this period. Talley Abbey was the first Premonstratensian abbey in Wales, while Llanllyr was a Cistercian nunnery, only the second nunnery to be founded in Wales and the first to prosper.
On Rhys ap Gruffydd's death the castle passed to his son Rhys Gryg, and the earliest parts of the present castle are thought to derive from this period. Llywelyn the Great of Gwynedd was now extending his infuence to this area, and Rhys, finding himself unable to resist, dismantled the castle. Llywelyn however had it restored and held it until his death in 1240. In 1255 Llywelyn the Last gave Dinefwr to Rhys Fychan, then later gave it to Maredudd ap Rhys before later returning it to Rhys Fychan. Maredydd now allied himself to King Edward I of England, and helped Edward capture Dinefwr in 1277. Maredudd had apparently been promised Dinefwr in return for his help, but Edward did not keep his promise and had Maredudd executed in 1291.
The castle now came into English hands, though it is recorded to have been burnt during the rebellion of Llywelyn Bren in 1316. In 1317 it was given to Hugh Despenser, the king's favourite. It was unsuccessfully besieged by the forces of Owain Glyndŵr in 1403. Towards the end of the 15th century the castle was held by Sir Rhys ap Thomas, who carried out extensive rebuilding. In 1531 his grandson was executed for treason and the castle was confiscated by the crown, though the family were later able to recover it. Around 1600 Newton House was built nearby and the castle keep modified as a summer house. The remains of the large windows can be seen at the top of the keep, but it burned down in the 1700s.