Subscribe to receive my FREE email course to help you improve your blog design and grow your audience with actionable exercises that do not require a designer or developer!
Over the past couple of weeks, I shared posts on how you should avoid deleting blog posts, how to transfer your website content from one domain to another, and all about WordPress permalinks. At some point in your website’s existence, you will need to set up a redirect to avoid an unpopular 404 error page.
What is a redirect?
A redirect tells the browser that a certain permalink has moved to a new permalink. Instead of someone getting a 404 error page, which often says something along the lines of “What you are looking for is no longer found”, they are directed to the updated permalink that has relevant content.
There are several different types of permalinks, but for today’s post, we will just focus on the 301 Redirects. A 301 Redirect is when a page on your site or the site itself has been moved. Content creators often use redirects for the following situations:
- Deleted page or post in favor of using new content
- Change the permalink of a page or post (especially if you want to SEO Optimize past permalinks)
If you do not create redirects, readers get error messages (404 Pages). Yuck!
How Do You Create Redirects
Fortunately, great plugins can help you setup and maintain your redirects. My favorite free plugin is Redirection; you are able to manage redirects directly in your WordPress dashboard. Redirection also identifies 404 errors on your site, so that you can easily redirect those broken links to working, relevant permalinks. If I need to set up 301 Redirects on a client project, I use Redirection.
Yoast SEO Premium includes a redirection manager (as well as the ability to use multiple keywords). I use YOAST SEO Premium for my own site, so if I do any redirections I use this plugin. The benefit of YOAST SEO Premium is that it integrates nicely with Google Search Console, so I can monitor my webmasters data concurrently.
The downside with these plugins is that the redirection is a little slower than the web server’s .htaccess configuration file. .htaccess redirects occur faster, but if you make a mistake editing your .htaccess file, your site will temporarily be inaccessible.
Connect to your website using an FTP client; the .htaccess file is found in your WordPress website’s root directory. Backup your .htaccess file before you edit it. You can then edit the file to include the redirect (preferably towards the bottom of the .htaccess file. For example:
RewriteEngine On Redirect 301 /old-blog-post/ http://www.yoursite.com/new-blog-post
That’s it! Your redirect should be set. If your redirect is not showing up, make sure to clear your cache. If you are using a CDN, you might run into a slight delay for a few minutes too.
If you know you need to set up some redirects for your site, I would recommend using the plugins rather than .htaccess changes. People tend to forget what changes they made to their site, and the plugins are the safest way to create, manage, and maintain your redirects.
Want more WordPress tutorials? Check out more posts!