Baseball caps should be washed. Learn how to de-funk it without turning your lucky hap into a weirdly misshapen object. Depending on the style of the hat there are several techniques that you could use to keep it looking brand new.
To wash a hat without ruining it you will need;
Cap buddy, or cage
Mild detergent without bleach
Baseball caps can be washed in your dishwasher. These are much more effective than a washing machine since there is no agitation and the hat can stay basically stationary while it gets clean.
Put the hat in a cap buddy, which is a little cage that can be purchased for a few dollars. Alternately you can simply place on the top rack with the brim resting on a glass to ensure the shape is kept intact.
Do all your ball caps and sporting equipment, like shin pads or wrist guards at one time. Please don’t try to wash dishes at the same time though!
Use mild dish washing detergent that does not have any bleach in it. Bleach crystals have ruined many a hat.
Stained hats can be soaked in cold water first. Then rub with pre wash treatment and let it sit for about an hour.
Rub the treatment in and then rinse thoroughly with cold water. Use a nail brush to rub the stains out. An old toothbrush or white washcloth will also work well.
Hang outside in the sun to let it dry naturally. White hats will especially respond well to this treatment. They will become whiter than white since the sun will help bleach them out even more.
Special hats with embroidery or other details that you don’t want to risk ruining under any circumstance should be taken to the dry cleaner. Collectibles and other special caps should be given special treatment. It is very inexpensive to have a hat dry cleaned and they will come back just like new.
Remember that wool hats should not be put in the dishwasher and that hats do not normally survive the dryer. Both will cause shrinkage and strange creases.