I would pre-book. My husband and I were in Scotland in late May/early June. We bought Historic Environment Scotland passes for our trip. Even on Iona where there were few visitors on the day of our visit, we were asked if we had made a reservation. I think booking just makes it easier for everyone, and it is easy to cancel your ticket and rebook if you need to do so. (I inadvertently booked our visit to Stirling Castle on the day I was on the website booking rather than the day I intended for us to visit. I realized the error and was able to correct the error via email quickly.)
At Edinburgh Castle I booked the first time slot available, and there was quite a crush of people when the site opened for the day. If you book, you know you will be granted entry within the 30-minute window of your time slot (at least at Historic Environment Scotland sites). If you are touring a site with a group, the pre-booking may not be important. We visited Culloden on a Rabbie's tour. Culloden is a National Trust for Scotland site rather than Historic Environment Scotland, and not knowing exactly what time we would arrive at the site with Rabbie's, I did not attempt to prebook.