One of the main causes of odor in a front loader washing machine is debris that gets trapped in the door gasket. The gasket seals the door tightly so water doesn't leak, but it also acts as a breeding ground for mildew and mold. Occasionally small items, such as socks, get stuck in the rubber gasket and become sour and smelly. Dirt and lingering detergent in the washer drum can also cause odors.
To remove the odor in a front loader, first gently pull back the rubber door seal. Run your fingers along this area to ensure that no clothing is stuck in the seal. Remove any clothing found. Mix a dilute solution of 3/4 cup chlorine bleach and 1 gallon warm water. Dip a soft cloth in the mixture and wipe the seal out, pulling the rubber gasket back to reach all areas of the seal. Wait five minutes and wipe the area dry with a clean cloth. If the odor is coming from the washer drum, add 1/3 cup bleach to the bleach dispenser drawer. Select a heavy cycle with hot water and an extra rinse, then run the washer with no clothing in it.
To prevent odors from building up in the washer, use a washer cleaning product once a month, following package directions. Wipe any remaining residue out with a clean cloth afterwards. Use only high efficiency detergent at the recommended amount. Traditional detergent creates excess suds and leaves a residue in the washer that can cause odors. Leave the door open between uses to allow the machine to air out and prevent mildew growth.
Be especially vigilant about cleaning the washing machine during the heat and humidity of summer, when mildew growth is most likely. If the problem continues, try switching laundry soaps and use only the recommended amount of fabric softener. Use hot or warm water to launder clothes when possible.