A slug is what appears within your site’s URL to specify the article or page people are seeing. It appears as http://example.com/blog/cat/your-slug. ‘Your-slug’ being the slug you’ve chosen. The slug has a very essential role in SEO as it appears on Google search result page. It’s further proof that your page is about what the title says it is.
Choosing the right slug is very important to your website’s SEO and readability.
This readability is also very important to your users and search engine algorithms. We try to explain WordPress slug and ways to choose it properly.
In this article, we discuss how to choose a WordPress slug for your posts and pages.
This is very important because you need to choose a slug for your posts before publishing them on your website. Doing so improves the post’s SEO.
You need to choose the perfect slug. Because it’s hard to change it after publishing the post.
What is WordPress Slug?
What is a slug in WordPress? In reality, a WordPress slug is an appeal and readable URL for your posts and pages.
In other words, the second part of your website’s URL. When in your permalinks configuration, you use %postname%, WordPress creates a slug for you.
Editing the post’s slug is very useful when your post’s name is very long or you may want to change it later in the future.
After publishing a post, it’s best not to change its slug. By changing a WordPress slug, your content will be displayed with another URL on the internet.
In other words, the previous URL will disappear as soon as you change the slug.
Is Slug a SEO Factor?
WordPress allows us to change a slug to increase our website’s ranking. This is very important for your website’s SEO.
This slug is also displayed to users on the search results page. The more readable a slug is the more users are attracted to it. Out of the results displayed on the results page, users click on a URL that has an attractive slug.
Based on what we talked about above, choosing the right slug is very important for your website’s SEO.
Therefore, you must be extra careful when choosing your slug.
Now that we know what is a slug in WordPress, we need to know how to choose the right slug.
How to Optimize WordPress Slug
How do you pick the perfect words? Based on what we discussed above, how do you choose the perfect slug? Let us give you some points.
Make sure you use space instead of a dash. Although, whether you use a space or not, WordPress does it for you. Make sure you are not using capital words in your WordPress slug.
How to Modify Slug in WordPress?
We discussed what is a slug in WordPress. Now it’s time to choose a slug.
How to Edit WordPress Post Slug?
To choose a slug for your posts in WordPress, follow the steps below.
When creating or editing a post, look under the Document bar on the right and side. Under Permalink you can see ‘URL Slug’.
By choosing a short slug, you can increase your click-through rate (CTR). Google algorithms pay extra attention to short and detailed slugs.
By publishing or updating a post, WordPress creates a slug for that specific post.
SEO experts strongly believe that users tend to click on short slugs more often. Even if your website is displayed minutes after a website with long slugs, users tend to click on the short slug.
Keep in mind, slugs generated automatically by WordPress may not have the characteristics mentioned above.
How to Change WordPress Post Slug?
Choosing a slug for your WordPress page is exactly like choosing a slug for a post. From your WordPress dashboard click on Pages, underneath your desired page click on Edit.
After editing or publishing your page, your WordPress slug is created.
How to Edit Slugs for Categories and Tags?
WordPress automatically chooses a slug for tags and categories. When you use the built-in editor in WordPress, based on the Name, it creates a slug for you.
Based on the points we discussed above, it’s best if you pick a slug yourself. To do so, follow the steps below:
From your WordPress dashboard, click on Posts. From the opened menu, click on Categories or Tags.
Underneath each category or tags, you may find Edit. Click on it. In the opened page, click on slug and type in your desired slug. By saving your changes, a slug is created.
How to Change WordPress Author Slug?
By default, a slug on the author’s page is usually the author’s name. Since you cannot change a user’s name in WordPress, you can use the Edit Author Slug plugin.
By installing and activating the plugin, you can change your author’s name in their user’s page.
The Difference Between Permalink and Slug in WordPress
Permalinks are used to build the structure of your website’s URL. This is accessible through your WordPress Settings > Permalinks.
A slug comes after your website’s domain name. To make sure your slug is displayed right after your domain name, follow the steps below:
- From Settings click on Permalinks.
- In the Common Setting section, choose your permalinks structure.
- %postname% uses the name of your post as the slug.
By selecting Post name in your Permalinks configuration, your WordPress slug is displayed exactly after your website’s URL. To see a more complete guide to change WordPress permalinks, see our other article.
Some Pointers Before Picking a Slug in WordPress
Here are some advice s to choose the best slug for your posts.
Keep it Simple and Short
It’s best not to use words that cause strokes in the sentence. It’s best to avoid using words such as “a”, “the” and “and”.
Using a short slug has some benefits. First, it may be used within a Breadcrumb. Also, using a short slug makes your website’s URL to be displayed better on mobile devices.
Delete any words you think won’t have a negative effect on the meaning.
Describe the Subject of Your Post
Try not to put way too much information in your slug. Although, make sure you put your subject in the slug.
Keep this point in mind, and make sure you don’t delete words that point out to your subject.
Put Keywords in Your Slug
Other than the points mentioned above, try to have your keywords in the slug as well.
Having keywords in your slug increases your website’s ranking. On the other hand, by seeing the keyword in Google’s search result page, users may click on your website.
Therefore, having keywords in your slug is very important for your website’s SEO.
Avoid Duplicating Slugs
Make sure a slug you use for your post is not used by another post, page or etc.
When you are editing your post before finally publishing it, make sure the number 2 is not at the end of your slug. This number means another post or page is using the same slug on your website.
This is very important when you want to use a single word slug. If this happens on your website frequently, simply avoid using single word slugs.
In some cases, unpublished posts may have the slug you would like you to use.
Make sure you empty your bin, posts in your bin still keep the slug you created for them.
After Publishing a Post, Do Not Change the Slug! (Unless you absolutely need to)
If you change a slug, every user who used the previous URL to access the post will face a 404 error. By changing the slug, you have changed the URL. Therefore, you lose your audience.
In this case, we recommend using 301 redirects. WordPress may do this for you automatically.
However, sometimes by changing Tags, and Categories slugs, WordPress may not redirect your content for you.
Therefore, it’s highly recommended to choose the right slug for your content and don’t change them.
Conclusion
In this article, we learned what is a slug in WordPress. By choosing the right slug, you may increase your website’s audience and improve your SEO.
Keep in mind, before publishing a post, make sure you are happy with the slug you have chosen. Changing the slug is not recommended. It is time-consuming and it has a negative effect on your website’s SEO.