When it comes to changing settings within WordPress, the permalink structure is something that people often leave alone after their blog is established. The permalink structure, however, is one of the most important settings within your blog. This setting dictates how your blog’s URLs are to be written and ultimately affects your SEO and readership.
If you have a blog with timeless or “evergreen” content (meaning that the posts are not at all related to the date), then I would suggest using the /%postname%/ permalink for both SEO and practicality purposes. The only type of website that should have dates in the permalinks is a news blog such as 9 to 5 Mac or CNN. The problem, however, is that the default WordPress permalinks include the date and many people do not think about changing the setting until it’s too late.
My permalink settings way back in 2012, were set to show the year, month, and then the post name. So a basic post written in December 2012 would have a permalink like www.omegaweb.com/2012/12/basic-post. Most of my content is evergreen content, so I wanted to change the structure to be www.omegaweb.com/basic-post instead.
Lucky for me (and you), the developer of the leading WordPress SEO plugin by Yoast has created a tutorial (don’t worry, you don’t need to use Yoast SEO) on how to change the permalink structure without losing Google rankings and backlinks from other sites.
1. Find Out What Permalink Structure You Use
The first step to changing your WordPress permalink settings is figuring out what configuration you are using now. To figure this out, go to Settings > Permalinks inside your WordPress dashboard.
2. Use the Yoast SEO Tool To Generate The Redirect Code
Now you need to use the Generate Redirects tool to create the code that you will need to add to your .htaccess file in step 3. Once you get to the tool, enter the URL of your blog, then select the current permalink structure that you discovered in step 1.
3. Add The Code To Your .htaccess File
When you hit the Generate Redirect, you will be given a single line of code that needs to be added to the top of your .htaccess file. If you don’t know what your .htaccess file is, I would suggest contacting your web host and asking them to change it for you.
4. Change Your Permalink Settings In WordPress
Now that you have the code added to your .htaccess file, you need to change the settings within your WordPress dashboard to make the redirect active. The code generator that I shared in step 2 only converts your current structure to /%postname%/ because it’s far superior to any of the other methods (according to Joost of Yoast SEO).
You will need to go to Settings > Permalinks and change the settings to post name. Once you do that, your new permalinks should be active and the old permalink structure should redirect to the new one.
Did You Run Into Any Problems?
Did you run into any troubles in the process of switching your permalink structure? Did it work perfectly for you? Let me know in the comments!
If you enjoyed this article, please be sure to share it with your friends. If you need help with a project or would like to refer a lead to us, please visit our web design website.
This was helpful; the only thing I had to do differently was to change the regex in the redirect rule to end in (.+)$ instead of (.*)$. The + requires at least one character after the last /, otherwise the URLs in the WordPress calendar widget didn’t work for links to specific days, i.e. /2013/02/01/ would mean $4 was blank, and would redirect to the main page.
I am using Nginx, so no valu of htaccess! 🙁
My website name is livewireworld.info
I read your post about. It is very well written and in very easy language to understand.
But my issue is little bit different.
My permalink structure was /%year%/%monthnum%/%postname%/ before 21st January, 2013. I redirected Attachment url to parent post url through Yoast’s seo plugin and it works.
But after 21st January, 2013, I change my permalink structure. /%category%/%postname%/%post_id%/
and I redirect my old permalink structure to new permalink structure. (with Simple 301 Redirects plugin)
I uncheck Attachment url to parent post url in Yoast’s seo plugin and then once again check the box of Attachment url to parent post url. So that refresh Yoast’s seo plugin and it works normally. But it works only with new permalink structure (/%category%/%postname%/%post_id%/), not working with the old permalink structure(/%year%/%monthnum%/%postname%/). And therefore it is result in so many 404 errors.
Attachment url to parent post url is working only for those post which I published after 21st January, 2013. Before this date I published almost 594 post and for all those post, Attachment url to parent post url doesn’t work. One solution is there with Simple 301 Redirects and it is that I have to redirect my each image of those 594 posts to their parent post url. You can understand, I have to redirect almost 3000 + images one by one.
I have trying lot to find out solution since last 20 days. But I have no solution. So kindly request you, Please suggest me how to get rid of this issue. I hope, I will get positive response.
Hi, if you could please post this if our forum? I will see if I can come up with an answer.
Thanks for the article, I was excited to try this out. Unfortunately, it did not work for me. When I used the Yoast Generate Redirects Tool it reported that I did not need to update, that WordPress would do this for me. It did not generate any code. This appears to be only partially true. Since I changed my permalink structure my backlinks appear to still work (good!), however I have lost all of my “likes” from Facebook (bad). My Facebook buttons are being called through a Facebook plugin in my content.php. Can you offer any advice to keep my pretty new /%postname%/ permalinks and get back my old Facebook likes?
Timely article. I agree with all the points you made.
Great Tips, when we are going to change permalink structure for a well esablished site, we always should care about some basic checks, the first and foremost is adding a permanent redirect.
I just saw a Google Hangout where Court from The Keyword Academy said to never change your permalink structure. I have never done it myself but it seems that running the Link Juice Keeper plugin would keep all the link juice on the site. Maybe not the specific page but within the blog itself.
He was probably meaning never to change your permalink structure without doing the redirect. If you do the redirect like I have mentioned here in this post, you won’t lose any link juice.
In present scenario, the internet marketing is getting too much stuff. Its strongly recommendation that we must always go through the foot print of great dignities in SEO marketing. Not an issue you have represented an almighty bundle of knowledge. It would be appreciated always.
Html5 Tutorial
Hello Ian,
That is a nice tutorial. I came to know about permalinks about one year back when I had to move my blog from blogger to wordpress. But that was easy.Thanks for this tutorial.
When I moved one blog from Blogger to WordPress, it was a mess. I didn’t even bother switching the permalinks because they were already broken links. Anyway, I’m glad I could help.
Thanks Ian, great post .. I have one of my older blogs with exactly this problem so I am off to try it out
Good luck, Andy!
Wow! This is an excellent article. This could help me out in the changes I’ve been planning to make. Thank you.
I’m glad I could help. Thanks for stopping by.
Thanks for this tutorial. 🙂 I thought that we can’t change permalink structure without losing our backlinks. Now I know that it is possible. 🙂
Technically, the backlinks are pointed to the old structure, but the redirect will make sure you don’t have any 404 errors.
Whoa! I am just looking for this.
Recently I bought a blog where the permalink structure is /%category%/%postname%.html.
I hate this structure because I need to add more categories for a post and I don’t want to mess URL with category.
So this will definitely help. Thanks
I don;t know if this would be the problem but I could not access to wp-admin of my blog.
That’s not normal… Try posting a thread on the WordPress support forums.
I’m glad I could help you out. I use that permalink structure with the category on one of my sites, but I agree, it’s not ideal for most.
Thanks for this informative post on this. I think I have some to do from when I moved from blogger to WordPress almost a year ago.
I moved one of my blogs (not this one) from Blogger to WordPress a while ago and permalinks were a complete mess… I wish I would’ve known this redirect trick then.
Nice post, Ian.
I also use the SEO plugin by Yoast.
There have been many times that this plugin has saved me so much time and effort.
I am also using a permalink plugin (I think called permalink finder) that is also quite useful…
I do not have the Yoast “Generate redirects tool” though, I already have redirect functionality…..which may be due to other plugins installed.for that purpose..(there are quite a few plugins there)….
The only time I have really needed to worry about permalinks, was when I came over from Blogger to WordPress(from memory) I used a plugin to keep permalink structure from messing up……..(Blogger and WordPress have a different permalink structure)…..
You don’t actually have to use the Yoast plugin to make this redirect work. It uses your .htaccess file on your web server.
However, Yoast SEO is a very good plugin and I just recently switched to it from All In One SEO.
Thank you so much ! Before reading this article, i don’t know how to change permanlink structure without losing my backlinks 🙁 It make me sad, and i don’t know that Yoast plugin can help at this problem, i’ll try it.
Thank you again !
It’s not actually the Yoast plugin, but it’s made by the same guy.