A lot of people rely on the date on the packaging to tell them when food has gone bad, even with eggs, but the "sell by" dates are often rather arbitrary, and do not correlate to expiration dates. If you've been tossing away your eggs based on the dates on your carton—you're wrong.
Your eyes and nose are the best tools for determining freshness with meats, produce and herbs, but you can't really use your senses to test an egg before you crack it (unless you're highly skilled).
Eggs are often still good to eat long after the date on the packaging says to throw them out. If you want to test how fresh they are before finding out the hard way, here are a few methods for testing them.
Just fill a bowl with cold water and place your eggs in the bowl. If they sink to the bottom and lay flat on their sides, they're very fresh. If they're a few weeks old but still good to eat, they'll stand on one end at the bottom of the bowl. If they float to the surface, they're no longer fresh enough to eat.
While you could fry or scramble an egg that's on its side or standing upright, when it comes to hard-boiling, you'll want the upright ones, as Yumi points out in her guide to peeling hard-boiled eggs.
Below, you can see what a really bad egg looks like in comparison to really fresh one. The one on the left is most likely 3 or more months old (from when it was laid, not the date you actually bought them).
To give you an idea of hold old an egg actually is, look at the "packed by" dates on the carton, which are in Julian date form by the "sell by" dates. Julian dates range from 1 to 365 days, and since most companies pack their eggs shortly after they're laid, it's a good indicator.
The reason this method works is because the eggshells are porous, which means they allow some air to get through. Fresh eggs have less air in them, so they sink to the bottom. But older eggs have had more time for the air to penetrate the shells, so they're more buoyant and will float.
Some people also claim you can hold an egg up to your ear and shake it to test for freshness. If you can hear a sloshing sound inside the egg, it's probably gone bad, but if you hear nothing, it's fine to eat. Personally, though, I don't think this method is as reliable.
Additionally, there is the candling method, which is used primarily for testing egg quality before putting eggs on the market, but it could help determine freshness too, though it's more difficult to see at later stages. Some just put a flashlight right next to the eggshell to light up the insides, but historically, a piece of cardboard with a small hole in it was used, with a light source behind it and the egg in front.
The above method will let you see the air space and mold, but it's really a difficult technique to get down.
Above you can see a fresh egg (little air space, slightly visible yolk), a slightly old egg (larger air space, slightly darker yolk), a nearly bad egg (really dark yolk, spotty), and a spoiled egg (mixed in yolk, lots of dark) using the candling technique.
If you don't need the shell intact, you can also crack the egg onto a plate or other flat surface to test how fresh it is. If it's fresh, the yolk should be bright yellow or orange and the white shouldn't spread much. If you're not sure, give it a good sniff: fresh eggs shouldn't have much of a smell at all.
If the egg is older, the yolk will be flatter and the white will be much more runny. An egg that spreads out when cracked isn't necessarily bad, though, just older (and again, good for hard-boiled eggs). If it's gone bad, you probably won't even need to do the sniff test—even slightly rotten eggs will have a very strong, distinct smell you'll notice right away.
There are also lots of things you can do with those discarded eggshells, like make your teapot super clean, fertilize soil, and make sidewalk chalk. And don't forget about those leftover egg cartons, which make good seed and fire starters, bird feeders, and candle-making molds.
Do you know of any other ways to test whether or not an egg is good to eat? Share your method with us in the comments.