Depth-of-Field is a photographic term that references the notional third dimension, or z-axis, of a photographic image. Of the various pieces of photography relating to the basics- shutter speed and aperture- it’s one of the more elusive for most people to grasp (although everybody appreciates a nice portrait with a blurred-out background). Effectively, it is the amount of the photograph front-to-back (or, from close to the lens to further away from the lens) that is sharp and in focus. It is controlled by aperture, which is the diaphragm, or hole, in the lens that allows light to reach the plate, film or sensor. A wide aperture (small f-stop number, counterintuitively, such as f/1.8) leaves relatively little of the photograph front-to-back in focus, while a narrow aperture (large f-stop number, such as f/22) leaves lots of the photograph in focus. So a portrait shot at f/3.5 may keep the person who is the subject of the photograph in focus while throwing the background into a nice pleasing blur (known among photographers nowadays as “bokeh”, a Japanese term). A landscape shot at f/22 may have everything in focus from just in front of the photographer (perhaps 1 metre away) all the way to the horizon.
Aperture of course has to be traded off with shutter-speed. Each increase in f/stop value (these are marked in half-intervals on your camera as the intervals which change when you choose to manually set your aperture on the “Av” or “Aperture Value” setting, and are universal) halves the amount of light which reaches the sensor, so you need to double your shutter-speed accordingly to keep the photograph correctly exposed.
The other effect aperture has is to increase or decrease the relative sharpness of that portion in focus. A wide aperture (narrow depth of field) also increases the sharpness of that small portion of the photo in focus. Conversely, a narrow aperture (large depth of field) such as a landscape with flowers in the foreground and mountains behind, may be in focus all the way from near to far, but the sharpness will be slightly less (although with a landscape you won’t notice the difference).
The final variable that comes in to play is that the actual depth of field is not set in stone, but rather is a function of the focal-length of the camera (that is, the distance from the lens that the central point of focus is)- hence the notation f/x where x is the aperture value. So if you focus on something 100 metres away, the depth of field before and beyond that point along that z-axis will be much larger than if you focus on something 5 metres away. In the above shot, the set of weights in my bedroom was about 50cm from my lens, shot at f/2.8. You can see that roughly 15mm of the shot is in focus front-to-back, and the rest blurs out. If I used the same focal length but focused on a tree out of my bedroom window 20 metres away, I could expect that a good metre or so either way from my point of focus would remain sharp before falling off.
As I said at the beginning, depth-of-field (DOF) is one of the less obvious applications of the regular photographic variables, but once mastered gives a great versatility and freedom in constructing portraits, landscapes, macro (close-up) and a variety of other photographs as well.
A couple more examples of photos using very shallow depth of field: