That greenish-gray ring around a hard-boiled egg yolk may look unappetizing, but it is not a sign of spoilage or unsafe food. As the article explains, “That greenish-gray ring is not a sign of bad eggs or unsafe food; it’s a sign of overcooking and slow cooling.”
The discoloration forms when eggs are exposed to too much heat for too long. In this process, “sulfur from the whites reacts with iron in the yolk, forming ferrous sulfide,” which creates the dull green rim. Leaving eggs in hot water after cooking can make the reaction even worse.
Fortunately, the issue is easy to avoid. Using “reasonably fresh eggs” and cooking them gently makes a big difference. Instead of a rolling boil, eggs should be cooked at “a simmer rather than a furious boil.”
Timing is also important. Eggs should be cooked “about 9–12 minutes, depending on size,” and then removed immediately from the heat. This prevents excess heat from continuing to cook the yolk.
To stop the process completely, the article recommends “plunging them into an ice bath or very cold running water.” With “controlled heat and rapid cooling,” yolks remain “golden, tender, and beautiful—no ring, no guesswork, just consistently perfect hard-boiled eggs.”