After I moved my blog from Blogger to WordPress I was left with a not very pretty custom permalink structure. I hated it but didn’t change it because I was afraid I might mess up the redirect. And all those posts that talk about how hard it is to change permalinks and how easy it is to lose referral and search engine traffic certainly didn’t help. Well, I recently decided to change them and it only took a few minutes.
Let’s take a look at permalinks and how to easily change WordPress permalinks without losing traffic:
What are permalinks?
Permalinks, short for permanent links, are the URLs to your blog posts, pages, and category and tags archives. They never change, unless you want to change them, and they are used to link to your content.
There are three types of permalinks:
Ugly permalinks
They look like this:
http://example.com/?p=204
This used to be the default WordPress permalink. It’s formed by your blog’s name, followed by a query string that shows your posts ID. They are called ugly because humans and search engines can’t read them.
Almost pretty permalinks
They look like this:
http://example.com/index.php/yyyy/mm/dd/post-name/
These are called PATHINFO permalinks and they include index.php after the domain name. Besides that, they act just like pretty permalinks.
Pretty permalinks
They look like this:
http://example.com/post-name/
These are the most common permalinks in WordPress or other sites. If you are using pretty permalinks, the domain name is usually followed by your post’s slug. The slug is a short and user-friendly version of your post’s name.
Pretty permalinks can also have the date or category before the post name.
Why you should use pretty permalinks
Everyone agrees that you should use pretty permalinks because they are good for SEO. There are even some SEO experts that claim your SEO improves if you have the date or category in your URL structure.
In my opinion, and that’s why I decided to change my permalinks, having only your post name after your domain name is the best structure. I think this is the most user-friendly option because it’s a simple URL that’s easy to read and emphasizes your keywords.
When to change WordPress permalinks
If you already have pretty or almost pretty permalinks, you don’t have to change the permalinks. Having the date or even that annoying .html extension in your URL will not affect your SEO, so you should only change them if you really want to and are not afraid to edit your .htaccess file.
I do advise you to change them if you have ugly permalinks because having your keywords in your URL will help your SEO.
How to change the permalink structure
Please be careful before you change your permalinks. If your blog is older and you have a lot of posts, you will have to set up a redirect to make sure there are no 404 errors. Another thing you have to consider before changing the permalinks is that you will lose the social share counts on your blog posts.
Changing the permalinks settings
The first thing you have to do is go to Settings > Permalinks in the WordPress admin area.
If you are using a custom permalink, please save it before switching to a new one.
I recommend using the ‘Post name’ permalink to make sure your page will be saved with a URL that reflects the title of your post or page.
Create redirects
Redirecting your old permalinks to the new ones is a very important step. This is something that’s rarely mentioned in posts that talk about changing permalinks.
You can easily do this with the Yoast SEO premium plugin.
If you don’t have the paid version of our favorite SEO plugin, Yoast will still help you. Just follow these steps.
Use this redirect tool to generate a code that will point your old URLs to your new URLs.
Add your blog’s name and select your old permalink from the list. If you have a custom permalink, paste it into the custom permalink box. Click ‘Generate Redirect’ and copy the highlighted code.
All you have left to do is use an FTP client or the File Manager from your cPanel to access your .htaccess file. The .htaccess is in your root directory, but you might not see it unless you force your FTP client to show hidden files.
Paste the redirect code at the top of the .htaccess file and save.
Go back to your blog and test your new permalinks. To make sure your redirects are working, try to access your posts from social media posts and test internal links.
Changing the permalink structure is easy and it takes less than a minute to do it, but please take some time to think about it and make sure you don’t skip the redirects.
Have you ever changed your permalinks? Do you want to?
I’m a bit confused. I used Yoest’s Create Redirects tool to generate a redirect for my .htacess file, but when I entered the type of permalink that I currently have (ugly), I was informed that I didn’t need any redirects. The website informed me: “You don’t have to do any redirects, WordPress will do it for you.”
Given you state on this page that for ugly permalinks redirects are still necessary, I’m now afraid to change my rather large (2,000+ pages) website’s permalinks to Post Name.
Perhaps I misunderstood. Do I need to worry about about the links to my pages from other sites? Internal links? Or don’t I need to worry?
Since my site’s creation in 2008 I have never had anything other than the default ugly permalinks, and figured that it was finally about time to do something about it. Now I just don’t know what to do.
Please advise one way or the other.
Thank you….helen