How to Change Permalink in WordPress
Channing the permalink in your website is a major undertaking. You should be absolutely sure you want to make this change to your site because it impacts your website in many aspects.
A good permalink improves user experience, organizes your website, and helps for better SEO rankings. In contrast, changing your permalink improperly will lead to the drop of traffic of your website.
This article gives you deep insight into what permalinks are and how to safely change permalinks, and avoid external and internal errors from broken links with the use of redirects.
Let’s get started.
- What Is Permalink in WordPress
- Why are Permalinks important?
- How to Create Custom Permalinks in WordPress?
- How to Setup Permalink Redirects and Avoid 404 Errors?
- Final Verdict
What Is Permalink in WordPress
Permalink derives from the term “permanent” and “hyperlink”. It’s “permanent” because the link isn’t meant to be changed, as this would break any existing links to the corresponding page.
Each page and post on your blog has a unique permanent URL, or “permalink”, assigned to it. For example, the permalink of this very blog post that you’re reading right now is:
How to Change Permalink in WordPress
Pro Tips: How WordPress Permalinks, Slugs and Links Are Different
To fully understand permalinks in WordPress, we also need to understand exactly what slugs and links are. What are the differences between them?
- A permalink is the full link to a page or post. The post link referenced earlier, https://seoasoorm.com/how-to-change-permalink-in-wordpress/ is a permalink.
- The slug is only the part that reads “how-to-change-permalink-in-wordpress”. It’s the last part of the permalink and is unique to only that post. When you apply a title to a post, WordPress generates the slug for it automatically based on that title you choose. If you prefer, you can also create a manual slug for a post right within your post editor.
- A link usually refers to the hyperlinks you use within your content on your website. Internal links help your readers navigate to content on your website, while external links are ways of referencing other websites, articles or blogs.
Why are Permalinks important?
Permalinks bring changes to three major aspects, including Website Structure, Search Engine Optimization, and User Experience.
- They allow your readers to get a brief understanding of what your post or page is about without looking at the content.
- They are used by search engines to discover the post or page topic solely from the URL because the permalink can contain relevant keywords.
- They make it easier for search engines to crawl your pages if your permalinks are organized in a structured hierarchy.
- They supply a permanent location for your visitors and search engines to return to in order to read your content.
- They are essentially a unique identifier for each piece of content you create, helping you keep everything organized.
How to Create Custom Permalinks in WordPress?
There are three ways to change permalinks in WordPress. The first changes your entire website’s URL structure, while the second enables you to change the permalinks of category or tags and the third will allows you to alter individual page or post URL.
Which method you use will depend on your situation, so we’ve covered all of them below.
Important Note: Before you make any changes to your site’s link structure, it’s important to make a backup of your site just in case.
Part 1: Change Your Site’s Permalink Structure
If you’ve just started a new site, changing its permalink structure will likely be a part of your initial setup process. Also, this process may be performed after migrating a WordPress website.
Here are the details on how to do it. You should have a clear plan for changing them before you do so.
Step #1. First, you can quickly view your permalink structure by logging into your WordPress admin dashboard and going to Settings > Permalinks. This is where you can change the structure of your permalinks for your entire site.
Step #2. In WordPress, permalinks are created using a predetermined structure. In the screenshot below, you can see the 6 custom permalink structures that WordPress displays as common settings. Choose one of the settings you want. I’m a strong advocate for Post Name when it comes to WordPress permalink.
Plain is the default permalink structure used by WordPress. If you don’t change any setting related to permalinks, WordPress will continue to use this structure for your URLs. It creates URLs based on the number of posts or pages published on your website.
Day and Name
This structure adds the article published date to the URL along with a slug. While you can change the date from the Publishing settings, you can’t remove it from the URL.
Month and Name
With this structure, you can add the published month of the posts instead of the date. It’s mainly used by magazine-type blogs and websites.
The numeric permalink structure is similar to the plain structure. But it adds the word archives to the URL and adds a number based on the number of posts published on your website.
Post Name structure is the simplest and most effective URL structure. It helps you to create a more descriptive URL that users can actually read and remember. It includes just the domain name and the slug.
When using a custom structure, you can put your creativity to the test and choose from a number of tags to create your own unique URL structure. You can add just the year, category, author name, and more to the URL using the available tags.
Step #3. After you’ve made your decision and selected the best option, save your changes or continue on to the Optional section.
In the earlier section, I’ve shown you how to change the permalink structure for the whole site. In this section, I will show you how to change the URL keywords for an individual category or tag.
Step #1. Go to Posts > Categories page and click on the Edit link below the category you want to customize.
Step # 2. WordPress will now load the category details. You’ll notice that WordPress automatically generated a unique slug based on the name given to the tag or category when it was first created. From here, you can change the category slug to customize its permalink.
Part 3: Change Permalink for an Individual Post or Page
WordPress uses your permalink structure as a template for your posts. But you can change the slug portion of the permalink for individual posts.
Step #1. Open a post in the editor. Then, click the gear icon to open the post settings.
Step #2. Open the post or page permalink Setting.
Step #3. Edit the URL Slug and Save
How to Setup Permalink Redirects and Avoid 404 Errors?
As we mentioned at the beginning, permalinks aren’t really meant to be changed and changing permalinks can break both internal and external links to your site. When users click on your original permalink, they will get a 404 page.
In that case, you’ll need to set up proper redirects to avoid 404 errors on your website.
You can set up page redirections easily, with the help of various WordPress plugins such as Redirection. This tool uses 301 redirects to automatically divert internet users from an old URL to the new one. This helps ensure that no website traffic is lost due to a broken link.
Step #1. install and activate the Redirection plugin.
Step #2. Upon activation, you need to visit Tools > Redirection page to set up redirects. You need to add the old link in the ‘Source URL’ field and the new URL in the ‘Target URL’ field.
It is always best to have a clear plan for permalink structures before you lunch a new site. When you have built a website already, it’s best to avoid changing URLs if you can. However, there are times when you have to change them. Then, follow the 3 steps below.
- Back up your WordPress site
- Change your permalinks
- Set up redirection so you don’t see WordPress 404 errors after changing permalinks
I hope that this step-by-step guide will help you change permalinks on your WordPress website smoothly and safely.