put it in the cold water cycle, hang dry.
some hats tho if its got crazy shit on it, ive hand washed in the sink with hot water and regular gel soap and a good hand towel
white hats though you gotta dab out like carpets
im too lazy to explain that one