Built by the Count of Schwarzburg in the 13th century, the ruins of Liebenstein Castle in the Ilm District are best known for the numerous legends and tales that have grown up around this historic site. The most widespread is the legend of the walled-in child, who is said to have been walled in there by a castle lord in accordance with a pagan belief to protect the castle. The castle ruins bear a strong resemblance to the remains of Ehrenstein Castle, which is about 25 kilometres away and was built by the same builder. Since the 17th century, Lieberstein Castle has increasingly fallen into disrepair, but in the meantime it was still used by the Dukes of Saxe-Gotha as a judicial office.