Replace outdoor extension cords every couple of years.
Every two to three years, or sooner if you see cracks, discoloration, or fraying. UV light and weather eat away at the insulation, and a damaged cord outside is a shock or fire risk.
The obvious signs: any crack in the rubber, exposed wires, or a plug that feels loose or hot after use. Also, if the cord feels stiff or brittle, toss it. Extension cords are cheap compared to a house fire.
Don’t try to patch outdoor cords with tape. That fails in rain or sun. Just buy a new one rated for outdoor use (look for “W” or “WA” on the label).
Future you doesn’t want to trace a blown breaker from a chewed-up cord.