Quick ad hoc visual representation of different apertures and depth of field...skipped over f/16, but let's not talk about that little bit.
Notice the depth of field, or parts of the image in focus, increases as the aperture gets smaller (larger number). At wide aperture of f/2.8, the depth of field is shallow enough, only the r/h side fender of the green matchbox car is in focus. Also notice in that same image the area in focus extends from left to right in a thin slice about the width of the front tire or a touch wider.
The exact distance the camera was from the subject, I don't recall. But suffice it to say, it was roughly 12", perhaps a touch more. Using a DOF calculator, f/2.8 would put the depth of field right around .040", while an aperture of f/32 gets us about 1.5"-2". Something to keep in mind, the depth of field is relative to the distance to the subject and focal length of the lens. For example, in our images the depth of field at f/2.8 using a 100mm lens is right around .040" at one foot. Move the camera further away, the depth of field is now 6" or so. Comparatively, with a 50mm lens, the DOF is now just shy of a 1/4" at one foot, and 24-1/2" at ten feet.
That being said, if you're trying to create an image and there is something you have no choice but to include...shoot at a wide aperture, focus good and tight on your subject, and blow the rest out of focus.
On the flip side of that...if you're shooting something that requires a greater depth of field (macro, close-up details, landscape, etc.) you would most likely opt for a narrower aperture to have more of your subject in focus.