This guide explains how to fix 404 errors on WordPress by redirecting users to another page or website. By default, if a visitor tries to open to a page that does not exist, WordPress returns a 404 error. 404 is the HTTP error code for page not found.
However, if you renamed or moved a page, it is a better experience to automatically send them to the correct page. Doing so can also preserve SEO ranking. You can do this with a plugin called Redirection by John Godley.
This guide assumes you have installed the plugin. If not, see How to redirect URLs on WordPress with the Redirection plugin. Once you have installed the plugin, you can check your 404 log and redirect any errors.
Instructions
- Sign into your WordPress site as an admin
- From the side menu, select Tools > Redirection
- To add a new redirection, click Add New
- Enter the source URL
This is the path that you want to redirect from. The source URL should begin with a forward slash (/). It may contain parameters, e.g.,
/?page=4
. By default, the exact parameter values must be matched (in any order), but you can change how parameters are processed. - Enter the target URL
You can specify a relative path starting with /, or an absolute URL starting with http:// or https://.
- Click the Add Redirect button
- Alternately, you can add redirects from the log file by clicking 404s
- If the list is empty, click Options to confirm you have enabled logging.
- Otherwise, review the 404 entries and determine whether you should redirect any of them
- To redirect an entry, move your mouse over the row and click Add Redirect
Since you are adding from the log, the Source URL will be filled
- Enter the target URL
You can start the URL with https:// or a forward slash.
- Click Add Redirect
Leave a Reply