Eliot Richards has rejoined Merthyr after a long period of injury.
The midfielder joined Hereford from Merthyr in 2017 and later had a spell at Barnet when Peter Beadle was in charge.
However last November Richards sustained multiple injuries in Barnet's FA Cup win over Burton Albion, including tears of his anterior cruciate ligament and meniscus.
"I'm absolutely delighted to get this deal over the line and get Eliot back at the Football Club.," said Merthyr manager Dean Clarke.
"Eliot is a player I know well, having spent time with the club before.
"He's a great professional who will offer a lot for us going forward. He's a player that wants to learn and improve, which is always a key ingredient in our recruitment."