Front and top loading washing machines can be deodorized by running the washer on the hot setting with two cups of bleach. It may be necessary to clean the interior lint trap, gaskets and dispensers of a front loading washer if mold or mildew is causing the smell.
According to Real Simple, unusual odors may be the result of detergent or softener buildup from when clothing is washed in cold water. To clean a washer that smells because of buildup, fill the empty washer with hot water, then add 2 cups of chlorine bleach, and allow the washer to complete a full wash cycle.
White vinegar can be used to remove odors in a top loading washing machine. To clean a top loading washer with white vinegar, allow the washer to fill with hot water and add two cups of white vinegar. Allow the washer to complete a full wash and rinse cycle. Adding a towel to the cleaning cycle helps remove buildup.
Front loading washing machines require cleaning around gaskets, removing and cleaning the dispenser and cleaning the lint filter to eliminate the odor of mold and mildew. Locate the lint trap using the owner's manual. Scrub the lint trap with a soft brush, then rinse and replace the filter. House Cleaning Central recommends using a mixture of one cup of water with one cup of vinegar or one tablespoon of chlorine bleach in one cup of water to clean the gasket and dispensers.