Puffballs come in two different sizes. Anything bigger than a (non-baby) potato or a baseball is in the genus Calvatia; puffballs the size of a golf ball or smaller are probably in the genera Lycoperdon or Bovista.
To test this, slice the fruiting body in half from top to bottom. Amanitas and some other mushrooms emerge from the ground enclosed in a white cottony "egg" that looks a bit like a puffball. But when you cut it in half, you will see the cap and stem of the baby mushroom inside (bottom left in the picture). If the cap and stem are white (as in the destroying angels), they are not as easy to see! Similarly, if your "puffball" is really a stinkhorn egg, you will be able to see all sorts of strange internal structures.
Checking for earthballs is a little more tricky; like puffballs, their interior is a solid, undifferentiated spore mass. There are a couple of ways to tell if you have an earthball instead of a puffball.
1) Except for Scleroderma geaster, earthballs max out at about the size of a golf ball. So if you have something significantly larger than this (and it's not an Amanita; stinkhorns also max out at about the size of a golf ball), you are pretty well assured that it's not an earthball.
Besides Scleroderma geaster, Pisolithus tinctorius is another large, inedible puffball-like fungus; but both of these usually break open and are blackish and powdery inside before they ever break ground.
2) Instead of ripening to yellow, an earthballspore mass ripens to a purplish-black color. So if some of your "puffballs" have turned (or are starting to turn) this color inside, they are earthballs.
3) Earthballs have a much thicker and tougher skin. If the skin of your (small) puffball is thicker than a millimeter or so, you probably have an earthball (the big Calvatias have a pretty thick skin also).
4) The puffballs' outer skin layer is white (sometimes brownish) and frequently has pointed spines on it that rub off. The Calvatias sometimes have spines that are a couple of inches high! Earthballs are usually yellowish on the outside (although there is one white one!) and their outer skin is frequently broken up into flat, tile-like sections.
5) The above guidelines are meant to maximize your safety, not to maximize the number of ediblespecies indicated. The only way to REALLY know what you're doing is to Know The Mushrooms (see Question 6). Get yourself a field guide. The large ones are fairly easy. With the small ones, once you can tell Lycoperdon pyriforme from Scleroderma citrinum, and Scleroderma cepa from the white Lycoperdon species, you'll be doing okay.
5) The above guidelines are meant to maximize your safety, not to maximize the number of ediblespecies indicated. The only way to REALLY know what you're doing is to Know The Mushrooms (see Question 6). Get yourself a field guide. The large ones are fairly easy. With the small ones, once you can tell Lycoperdon pyriforme from Scleroderma citrinum, and Scleroderma cepa from the white Lycoperdon species, you'll be doing okay. It's not so easy from the pictures, is it? :-) For more info, see the entry on puffballs.
As a puffball ripens, its spore mass will change color from a pure, uniform white to yellow. As it turns yellow, it also gets more squishy, and starts to smell like urine. You would think we wouldn't have to warn people not to eat them in this condition. As soon as the spore mass shows the least hint of yellow, it gets (especially in the smaller ones) very, very bitter, and can embitter an entire dish if it is cooked with other things. So you have to make sure that none of the puffballs you use have begun to ripen.