When you create a post or page on your site, WordPress automatically a new URL structure called a ‘permalink’ that is permanent and unique. Each permalink is created using a predefined structure.
By default, WordPress uses URLs like this http://example.com/?p=24. This URL structure is not SEO friendly. Permalinks have a great impact on your search engine rankings and are responsible for driving traffic to your site.
So, why not change the permalinks with something more meaningful and easily readable?
In this tutorial, I’ll discuss what permalinks are and talk about why it matters. I’ll also share how permalinks impact on SEO and reasons for changing them on your site. Further, I will provide the instructions on how to change permalinks in WordPress and fix the broken links.
Let’s get started.
- 1 What are Permalinks?
- 2 Why Permalinks matter and you should change it?
- 3 How URL Structure Affects SEO?
- 4 Change Permalinks In WordPress
- 5 Setting up 301 Redirects to Fix Broken Links
- 6 Final Thoughts
A permalink is a permanent hyperlink that represents the web address of your content. The permalink consists of your domain name and the slug of your content. For example, if take a look at the URL for this article: https://wphelpguide.com/change-permalinks-in-wordpress. The domain name is wphelpguide.com and the slug is change-permalinks-in-wordpress.
The default permalink structure is like this – https://wphelpguide.com/?p=24. This URL cannot be easily interpreted and doesn’t make any sense to human or search engines.
Now, let's look at another permalink structure – https://wphelpguide.com/change-permalinks-in-wordpress. This URL structure makes more sense and you get an idea of what this content will include. Further, it also more easily readable by humans and better for search engines indexing.
Permalinks when set correctly, serve many advantages. Some are as follows:
- They allow your readers to get a sneak peek of what your post or page is about without actually visiting the content.
- Search engines use them to discover page or page to index them.
- They make easier to identify all your content and keep them organized
- Permalinks are permanent addresses so search engines and your readers can return anytime to read your content.
There can be several reasons for you to change your permalinks. If you are just starting your site, you can change right away. Changing the permalink on an existing site can have some impacts on your site such leading your 404 errors, drop in site traffic and few others. I will cover how to tackle such cases in the later part.
Some of the valid reasons to change permalinks:
- If your WordPress site is using default permalink type that has post or page ID. You should change it immediately, as it provides no information and hence is useless for SEO.
- If you’re migrating your site, changing your content or updating it.
Still not convinced? Read further to know how it affects your SEO.
What's the use of having a site that doesn’t generate traffic? All your hard work and efforts will go in vain if your content is not ranked on search engines.
The URL structure for each post and page impact the search engine ranking of your entire website. The strategically created permalink ranks higher on search engines and brings more traffic to your site.
You can research on the keyword you want your posts or pages to rank. You can use those keywords in the title, tags, and slug to make more sense and easy crawling on search engines. For example, take a look at a typical post’s URL:
While this permalink contains the title and makes sense to the readers, it doesn’t have much impact on your SEO. Instead, you can target your audience with more specific keywords such as:
In short, your URL structure is simple and makes more sense. You should avoid using dynamic parameters in the URL as much as possible.
With that being said, let’s get to work!
Now that you are aware of the advantages and importance of changing permalinks on your site, it’s time to learn how you can do it.
You can access the permalinks settings within your dashboard under Settings > Permalinks. You will see a screen like this:
By default, it is set to Day and name. You need to change it to the Post name as shown in the screenshot above.
Once you make a selection, click on Save Changes. Now, your permalinks are updated. This will update all of your URLs with the new permalink structure.
However, the manual links needs to be updated. Further, any links to your site from elsewhere will be completely broken and throw 404 not found errors. We will get back on how to fix it later.
As you create posts or pages, WordPress automatically generates a URL based on the title of the post/page. It is also known as slug or permalink.
This URL structure is based on your WordPress permalinks settings. You can quickly edit it and customize this URL as you need. Don’t worry, it won’t affect your permalink settings.
If you want to quickly update your permalinks, you can do it using the Quick Edit option. To do so, go to Posts > All Posts or Pages > All Pages and click on Quick Edit link for the post/page you want to change the permalink.
Like posts and pages, you can also change permalinks for your categories and tags. To change it, navigate to Posts > Categories (to change categories slug) or Posts > Tags (to change tags slug) and click on the category you want to change the slug.
On the next screen, you can see the details about your category. Under Slug, customize the permalinks as you need and click on Update to publish the changes.
You can also use the Quick Edit feature to update the slug, like I demonstrated earlier.
Using the same methods, you can change the URL structure of the tags from Posts > Tags.
In WordPress permalinks settings affect your entire site. What if you want your own customize permalinks structure for your individual post, page, category or tag?
Sadly, you cannot do it from permalinks settings. However, you can do this using a plugin. Custom Permalinks lets you define your own permalinks for your contents.
To get started, you need to install this plugin. You can check our guide on how to install a WordPress plugin easily.
After activating the plugin, go to Posts > All Posts and edit the post you want to customize the permalink. In Block editor, you will see the permalink option at the bottom of editor. Here, you can change the permalink as you want as shown in the screenshot below.
As you can see, I have added wordpress-tutorials/ in the slug. After defining the slug, don’t forget to update the post.
You can repeat the same process to change permalinks for pages, categories, tags or any custom post type.
This will not affect the permalinks structure of other posts, pages, categories or tags. Others will inherit the permalink structure that you have set under Settings > Permalinks.
Changing the structure of the permalink is the easy part. However, it is necessary to redirect those posts or pages. You need to create a 301 redirect (permanent) for every old permalink to the new permalink.
If you change the permalinks of the indexed content, you need to configure the redirect. Otherwise, all those contents will throw a 404 not found errors. This is not only bad for readers, but it also impacts your site’s SEO and hurts your search engine rankings.
A simple solution to this problem is to use 301 redirects. A 301 redirect tells the browser about the change of the old permalink and navigates them to the new address. Further, it also informs the search engines that the content has been moved to the new URL.
For this purpose, you need to install and activate any redirection plugin. Redirection is a popular plugin that you can use. It manages 301 redirections and also keeps track of 404 errors.
To begin, at first install the plugin via Plugins > Add New > Search for “redirection”. From the search results, click to install and activate the plugin.
Once you activate the plugin, navigate to Tools > Redirection. You will see a screen as shown below with the instruction to use the plugin. Go through the instructions and click on Start Setup.
On the next screen, you will be prompted with some options to enable permalink changes, keep a log of all redirects and 404 pages and store IP information. Enable all the available options to get the most out of this plugin and click on Finish Setup.
Now, the plugin will start setting up the Redirection plugin based on the option you selected earlier.
Once you click on the Finish button, you will be taken to the plugin dashboard. Here, you can add the redirection for the old permalink to the new permalink.
To add the 301 redirections, add the old permalink in the Source URL field and the new permalink in the Target URL field as shown below.
You can leave all other parameters (Query Parameters and Group) with the default value. Finally, click on Add Redirect button.
Once you add it, it will be listed above as shown in this screenshot.
You can repeat the process to configure the remaining 301 redirections for the old permalink.
In case you want to modify, delete, disable or check redirects, you can hover over the URL to get these options.
That’s it! This is how you can change permalinks in WordPress on your site. It is always best to change the permalinks before you launch your site. However, if you change your permalinks after your site is launched, you need to redirect all the new permalinks to avoid disruption and effects on your site rankings.
If you have any questions or opinions to share, please feel free to let me know in the comment section below. I am always here to help.