Most people do not think about cleaning their mattress unless it has visible dirt or liquid was spilled on it, however your mattress should actually be cleaned at least every 6 months (consider cleaning it at daylight savings time when you change your smoke detector batteries and rotate your mattress).
Here are the steps for cleaning a mattress.
Your mattress contains lots of yucky stuff such as dust mites, dead skin, and other nasties.
Use your vacuum to get that stuff off of your mattress.
Vacuum the top, sides, and bottom of your mattress.
Pay special attention to the cracks and crevices at the corners of your mattress.
You may want to sprinkle your mattress with baking soda and leave it on for 1 hour prior to vacuuming to absorb odors.
Using specially formulated upholstery shampoo or a mild soap and water, scrub your mattress to remove dirt and odors.
Do not use too much water since it will need to dry completely.
Blot dry with a dry towel after cleaning.
If your mattress is a bit dirtier, or you are doing your yearly spring cleaning, consider using a steam cleaner to clean your mattress.
If you don't own a steam cleaner, you can rent one at many big box stores or supermarkets.
Allow at least 4 hours for a mattress to dry after steam cleaning.
Never steam clean memory foam mattresses.
If any liquid or bodily fluid (blood, sweat, urine, vomit, etc) gets on the mattress, absorb as much of the liquid as possible with a dry towel.
After you have absorbed as much as possible, wipe your mattress using a damp towel.
After that, clean it using upholstery shampoo or a mild soap and water.
You can also use vinegar and baking soda if you wish.
Hydrogen peroxide works well for removing blood stains.
You may use a ceiling fan or portable fan near your mattress after it is clean to help it dry completely.
Another option is to use a hair dryer or bring the mattress outside to let it dry in the sun.
Memory Foam Mattress Warning....
Memory foam mattresses are not supposed to get wet at all.
Avoid putting any water on your memory foam mattress and never steam clean.
If your mattress is not clean enough, consider hiring a professional mattress cleaner.