As a website owner, you’ve probably heard of 301 redirects.
But have you ever come across a 308 Permanent Redirect status code?
Those are less well-known but could be just as crucial to your marketing efforts.
Here's everything you should know about the 308 Permanent Redirect status code and proven strategies for fixing it without causing further damage to your website.
Before we answer this question, let's first take a look at how the internet works.
There are two main players on the internet: servers and clients.
Let's say that you're using your browser to open a web page. You're accessing the internet through a web client.
The web client sends a message to the server with your request to access the web page. The server returns an HTTP status code every time you make a request to your server to access a resource.
That status code can be a successful request, a client error, or a server error. In fact, there are five groups of HTTP response status codes, including:
1xx status codes: Informational requests
2xx status codes: Successful requests
3xx status codes: Redirects
4xx status codes: Client errors
5xx status codes: Server errors
Although somewhat different, they all inform a user whether a specific HTTP request has been successfully completed.
The 308 Permanent Redirect that we're looking into today belongs to the 3xx status codes group or the redirects. Some status codes in the group – like the 301 Moved Permanently and the 307 Temporary Redirect – can directly affect the user experience and the SEO health of your site.
To compare, the status codes in the 4xx group – like the 404 Not Found error – indicate there's an error on the client-side of things. The 5xx status codes, on the other hand, indicate that something on the server-side of things is the cause of the problem.
Since the 308 Permanent Redirect indicates that something on the server-side of things is the issue, we can entirely ignore the client-side of things.
301 Moved Permanently: The 301 redirect is one of the most common redirects. It indicates that the resource has been permanently moved and request method conversion from POST to GET is allowed. You should use this redirect if you want to redirect a moved or a deleted page permanently or if you have changed the structure of your permalinks. Make sure you always add a 301 redirect to your deleted or moved pages to avoid a 404 error.
302 Found: The 302 redirect is a temporary redirect that redirects users and search engines to a different page for a limited amount of time. It indicates that the resource has been temporarily moved and request method conversion from POST to GET is allowed. Use this redirect when you're redesigning or updating your website.
307 Temporary Redirect: A 307 Temporary Redirect is the HTTP 1.1 successor of the 302 redirects. It indicates that the resource has been temporarily moved and request method conversion from POST to GET is forbidden.
308 Permanent Redirect: As you can see from the list above, this set of codes is missing a status code that indicates a permanent redirect that forbids POST to GET conversion. This is the role of the 308 status code.
The first 'real' tip on the list is to check if there are any unintentional redirect instructions in your web server's configuration files.
Your application is either running on Apache or Nginx web servers. If it's on an Apache server, then both apache_server and .htaccess need to be checked.
If you're using Nginx, only one file needs checking: namely, nginx_conf_. After you locate the files, search for a 308 status code and see if anything appears. If it does, you need to modify it. You either want to remove it entirely if you don't need the status code or apply it to a specific page.
Nearly every web application keeps some form of server-side logs. Application logs are usually the history of what the application did while running a website.
If the troubleshooting tip above didn't help fix the issue, the root of the problem may be in some custom code within your application.
To see if this is the case, you have to debug your application code manually. Perform a step-by-step debug process to recreate the exact scenario in which the 308 Permanent Redirect occurred and view the application code when something goes wrong.
A 308 Permanent Redirect status code indicates that the resource the user tried to access has moved to a new URI.
The best way to fix the 308 Permanent Redirect status code is to:
Confirm your server configuration
Debug your application code
As seen in