WordPress Slug: What It Is and Why It Matters

WordPress Slug: What It Is and Why It Matters

WordPress is the most popular Content Management System or CMS that powers 37.8% of all websites globally, at the time of writing. It is easy to use, open-sourced, cost effective, and supported by a vast community of users all over the world. It is also SEO-friendly.

One of the most important SEO-related features of WordPress is slug. A slug is a part of the URL of individual pages, blog posts, and landing pages on your WordPress website.

In this post, we’ll be learning about what a WordPress slug is and how to use it correctly on your site.

 

A. What Is WordPress Slug?

As mentioned, a slug is a part of the URL that describes what the page is about. This text appears right after your domain name. You can add unique slug for each page, which is an important step in optimizing and building your WordPress site.

 

For example, in the following URL, https://www.unlimitedwp.com is the main URL while /faq is the slug, which tells you and search engines that this is an FAQ page for the UnlimitedWP website.

 

Sometimes, you will see more than one slug after the main URL or domain name as seen in the following example. In this example, the slug “blog” indicates a section of the website and “remote team management mistakes” describes what the actual page is about.

 

B. Types of Slugs You Can Set

By default, WordPress offers you complete control over setting up slugs for your website. Here are few types of slugs you can set for your WordPress site.

    1. Author Slug

This slug comes in handy if you have a blog with multiple authors and guest contributors on your website. It categorizes the posts by author-name. However, you need to use a plugin to edit the Author slug. You can add new authors and edit or delete existing ones using a plugin.

The Edit Author Slug plugin is an excellent choice. It allows you to change both the author and the author slug. It has over 100,000 active installations and works on WordPress version 4.9 and above.

    1. Tag/Category Slug

You can add different categories and tags to your blogposts and webpages using these slugs. Both options are available under the Posts menu. You can edit and update the pre-existing categories as per your needs.

    1. Post Slug

You can also add a Post slug to each of your post. You can add it while writing or editing your post. Go to the Permalink URL located right below the post’s title. Click the Edit button to change your Post slug. Click OK to finish.

    1. Page Slug

Similarly, you can add a Page slug for each one of your webpages. Just like the Post slug, click edit on the Permalink box and OK when you are finished editing.

 

C. Importance of Slugs for SEO

Slugs play a critical role in improving your on-site SEO. For example, you will see that a Post slug is almost always the title of the post. In other words, slugs can help search engines understand what your post or webpage is about.

For example, the following slug tells you the exact location and purpose of the blog post page.

 

 

So, when you type relevant keywords in Google, you can see this page popping up in the search results. However, if the slug had only a random post number without any relevant keywords, search engines such as Google will have a tough time finding the post. Furthermore, well-written and relevant slugs can also help people remember a particular URL easily.

 

D. Tips for Setting Slugs in WordPress

To make sure your slugs serve their purpose, you need to keep a few things in mind. For starters, you have to replace spaces between words with hyphens, and always use lowercase. WordPress will take care of these basic factors by default. But you will need to keep the following things in mind yourself.

    1. Cut the Clutter

One of the key elements that define a well-written slug is its length. It should be short and to-the-point. Make sure it clearly describes what the URL is about without stuffing it with unnecessary words. For example, you can avoid using words like “a” and “the,” among other things to shorten the length.

    1. Be Descriptive

Although the slug needs to be as short as possible, it also needs to describe what it is about correctly. You can’t afford to compromise relevancy when creating the slug. Avoid eliminating the words that are relevant to your page content and your keywords.

    1. Use Redirects

Redirects are useful if your WordPress slugs are a mess or you need to change them based on the change in the content. Changing a slug after you have published it can be a bit of a headache.

If you change the slug, people will have difficulty in accessing the webpage with the original slug. While WordPress will automatically redirect these users, it may not always work.

In other words, you will need to use redirects manually. If you don’t, users will see a “404 Not Found” or “404 Page Not Found” error, which will put them off. You will also lose incoming Web traffic and the SEO juice coming from that slug.

You can either edit your .htaccess file or use one of the redirect plugins to resolve this issue. Using a plugin is much easier compared to editing the .htaccess file. There are different 301 redirect plugins you can use.

With over a million active installations, Redirection is one of the best plugins out there. You can easily manage 301 redirections and keep track of 404 errors using this plugin. However, you should avoid editing slugs after publishing them unless absolutely necessary as they can damage your SEO and Web traffic.

    1. Use Your Keywords

 Although this is a no-brainer, it needs to be said. Including the relevant keywords in your slug will increase the search engine discoverability of that page. So, make it count. However, make sure the keywords fit in naturally.

 

    1. Avoid Duplication

Sometimes, you may see the number “2” in a WordPress slug. As WordPress doesn’t allow you to create two pages or posts with the same slug, it often adds the number 2 to avoid duplication.

However, this isn’t desirable from the UX and SEO points of view. So, you can manually edit the slug and add a slightly different variation. You can still see deleted posts in the page/post trash archive. Make sure to empty the trash archive to ensure posts with duplicate slugs are permanently deleted from your site.

 

Conclusion

As you can see, WordPress slug is an important aspect of your website. It can help boost your SEO and provide you with more link juice. Hopefully, understanding what a WordPress slug is and how to set it up can help you master this aspect of optimizing your website. How do you like to set up your WordPress slugs? Do let us know in the comments section.

    WordPress Plugins

    Start selling products, sending newsletters, publishing ads, and more through your own WordPress website using our premium WordPress plugins.

    Browse
    Comments

    No comments yet

    Leave a Reply

    Your email address will not be published. Required fields are marked *

    This site uses Akismet to reduce spam. Learn how your comment data is processed.

    Save 15% On All Purchases

    Use this amazing, limited offer and SAVE BIG! Buy any of our WordPress plugins, extension plugins or newsletter templates.

    Save 15% On All Purchases

    You have Successfully Subscribed!

    Pin It on Pinterest