Intermediate WordPress User

0 of 33 lessons complete (0%)

Settings

Managing Settings: Permalinks

This is a preview lesson

Register or sign in to take this lesson.

Transcript

Introduction

In this lesson, we will discuss permalinks and explore permalink settings. The learning outcomes are defining permalinks and slugs, changing permalinks using the built-in WordPress settings, modifying category and tag links, and redirecting links using a plugin. So, let’s get started.

Permalinks and slugs

What are permalinks? Permalinks stand for permanent links. They are the permanent URLs that point to a specific page or post. And the latter part of your URL that comes after the domain name is called the slug. They are user-friendly names to help search engines and users understand the content of the page. Slugs tend to be very similar to the original title of the post or page, or exactly the same. Take note, if a title is more than one word, spaces are replaced by a hyphen, as in the example here. Let’s see this in action and open one of the pages on the front end of my website. When we take a closer look at the permalink, we will see the permalink ends with the page’s name, namely the slug. Now, we are going to focus our attention on posts. So let’s open up our first post, The World is Your Oyster, and as you will see, the permalink has a date as well as the name of the post.

Settings

Let’s take a closer look at the permalink settings for our site. When we are in our dashboard, we will make our way to settings and then click on Permalinks. Below Common Settings, we will see that the default settings for WordPress is “Day and Name”. But what does that mean? It means that the slug of a page will include the name of the page, but the slug of a blog post will include the date as well as the name of the post. Let’s change the setting to “Only Display the Post Name”. You can also select one of the other options available or create your own custom structure using their available tags. Once you have saved your changes, let’s go back to our website to see how the permalink structure for a blog post has changed. When we look at the permalink, we see that the date is no longer there.

Change the permalink of an individual post or page

Next, you also have the option to change the permalink of an individual post or page. I’ve created a new blog post and called it “Be on guard and vigilant as there are pickpockets anywhere and everywhere.” And once we open our blog post, we have quite a long permalink. Let’s modify that to make it more user-friendly. Let’s return to our dashboard, open the post, and in the sidebar settings, click on the URL. The URL slug is the entire name of the post. So let’s replace that by typing in Pickpockets only. Once we click on Update, we can view the post on the front end, and now the slug only displays ‘pickpockets.’

Categories and tags

Lastly, let’s discuss permalinks for categories and tags. Let’s open the World is your Oyster post. Scroll down, and you will see a category called Travel and a tag called Adventure. Let’s click on Travel. This page will, of course, display all posts that have been assigned to the travel category. The permalink will include the word ‘category’ and then the category’s name, in this case, ‘travel.’ But if we go to permalink settings, we can change the word ‘category’ or ‘tag.’ At the bottom below optional, it says if you like, you may enter custom structures for your category and tag URLs here. So instead of saying ‘categories’, we can change it to ‘topics.’ And instead of your tag permalink saying ‘tags’, it can say ‘key words’ for example. To see this applied on the front end, let’s open up the World is your Oyster post. Scroll down and then click on the travel category. The permalink now says ‘topics’ and ‘travel’, not ‘categories’ and ‘travel’ anymore.

Redirects

Finally, we have to talk about redirecting permalinks. Ensure you only change link structures when a blog post or page is new. If you change an old permalink on an established website, visitors will not automatically be redirected to the new link. So, if you don’t want to affect your search engine ranking or traffic to your established site, you need to install a plugin to redirect your old URLs. Let’s go to Plugins, Add New, and in the search box, type in ‘Redirect links.’ There are different options to choose from, but I’m going to install an open-source plugin called Redirection. When you are ready, click on Install and then activate the plugin. Once the plugin is installed, click on Settings. Then go ahead and click on Start Setup. Once you have completed all the steps, click on Ready to Begin. When you are on the options page, click on Redirects on the top left. Here, you can redirect old URLs. The source URL refers to your old permalink or URL. The target URL is the new URL that you will be using. Let’s use our pickpocket post as an example. So, next to the source URL, enter the old permalink. And next to the target URL, let’s paste our new permalink. When you are ready, add a redirect. So now, when somebody clicks on your old link on an established site, they will be redirected to the new URL.

Conclusion

I trust you now have a better grasp on managing your permalinks.