by pcr910303 on 9/20/22, 8:15 AM with 14 comments
by ademarre on 9/23/22, 7:36 AM
It is true that browsers will cache 301 redirects eternally, but only if the server does not supply cache directives to indicate otherwise. For this reason, it is always advisable to include some cache directives in 301 redirect responses, like `Cache-Control: max-age=86400`. I'm surprised that this isn't more universally acknowledged as an important practice.
As far as search engines, there will not be a problem if a URL that used to return a 301 now returns a 200. The web changes, and search engines know that very well.
Add: There also seems to be a lot of confusion about the meaning of permanent. Permanent should not be taken to mean eternal. If I move to a new house, I consider that a permanent move, because I no longer live at the old address. But it would be unreasonable to assume that I will never move again. I might even move back to the original house! Such moves are like permanent redirects; I might have my mail forwarded, but it is not an indelible, eternal change. Temporary redirects (302, 303, 307) are more like leaving a sticky note on the door while you're out running an errand; you have not permanently relocated.
by silverwind on 9/23/22, 6:03 AM
by alserio on 9/23/22, 7:19 AM
by wumpus on 9/23/22, 6:48 AM
by weird-eye-issue on 9/23/22, 5:32 AM