The castle in Capdepera is located at the top of a high hill that can be reached via a walk up the road (fairly steep), or via the roughly 110 steps up towards the castle itself.
There is one entrance into the castle, with the fee being 3 Euros per person, and children under the age of 8 free of charge. The castle itself is fairly uninteresting for children, however, it is still worth a visit for families to learn about the history, which is provided by many info boards around the various areas in the castle, as well as the church and the 360 degree views from the top. There is also a church that can be visited at the very top and a museum depicting the tools of the time.
Make sure to bring along water on hot days, as there is nothing within the vicinity until you return to the center of town, where you'll find plenty of free parking areas and a few restaurants.
Opening hours vary depending on the season. Please check their website for info regarding opening times.