Yes hard boiled eggs do go bad if not refrigerated.
Hard boiled eggs are okay for awhile out of the refrigerator such as for Easter Egg Hunts etc but if you're not gonna eat the hard boiled eggs within the same day you should refrigerate them.
When refrigerated the hard boiled eggs should keep for 5 days to 7 days.
It's best to eat the hard boiled eggs within 5 days for the best taste and freshness.
Or you could freeze the hard boiled eggs and then thaw them out when you're ready to eat them.
Frozen hard boiled eggs should keep for up to a few months or even 6 months or so before they go bad.