Canning is the preservation of food in airtight cans, generally under pressure and/or heat. It is used to preserve vegetables, fruit, fish, and meat. Canning prevents spoilage by halting microbial growth, eliminating oxygen (and related oxidation), and destroying enzymes. Proper canning procedures allow foods to be stored for long periods without refrigeration. However, canning is not perfect and some spoilage can occur, requiring care and attention. Clostridium botulinum (which causes botulism) is one organism which can survive the canning process upon occasion.
Two main types of home canning are commonly used today: hot water baths and pressure canners. Pressure canners must be used for low-acid foods (such as meat, fish, and some vegetables) while hot water baths can be used for acidic foods only. Foods can be naturally acidic, such as applesauce, or have added acids, like vinegar. Pint or quart glass jars are generally used with single use self-sealing lids.
In a hot water bath, filled jars are immersed in a canner full of hot water. The canner is brought to a boil, and the jars are boiled for the given period of time. During the process time, the vapors and expansion of the jar contents force the air out of the jars, creating a vacuum.
A similar process occurs in a pressure canner, except the increased pressure within the canner allows processing to occur at a higher temperature. The higher temperatures are more effective at killing microorganisms, allowing low acid foods to be preserved.
Cleanliness is a key component of successful canning. Using sterilized jars, well washed and trimmed produce, and clean equipment prevents introducing microbial contamination and unwanted detrius.
See also 
National Center for Home Preservation University of Georgia Extension Service
Freshpreserving.com Ball® Jar's company website