The answer is every five years. Manufacturers and plumbers know these things. The rest of us, not so much. Seems the hoses get dry, rot and spring leaks. The same plumbing site says you should change the "discharge hose" (the one with the goose neck that sends waste water into the sewer) about every 5-10 years, too.
The site says these hoses can last 30 years, but it's not a good idea to test the limits. Stainless steel hoses--which last a good bit longer than the standards--cost about $17 a pair. One plumber recommends you turn off the water supply when you're not using the washer. Good luck with that.
One other suggestion: while you're behind the washer, you're probably going to be behind the dryer, too. Take your vacuum and clean the lent from your dryer's vent. When I moved into my house, there were a washer and dryer in the basement. I replaced the washer with a new one and replaced the 15-foot, ambling dryer hose with a three-footer that vents into the basement--with a filter. The long vent hose was clogged and it dang near worked my dryer to death without drying the clothes. I'm saving a ton of energy with the short hose, too.