I learned this from Flylady and I think it is brilliant to do it this way. My hard-boiled eggs are never broken anymore.
• Put your eggs in a large pan
• Fill your pan with cold tap water until almost filled
• Cook on the stove on the highest heat possible until big bubbles appear
• Turn off the heat and let them cool down in the water, several hours, until the water is cold. I do this usually overnight.