What is a slug and how to optimise it for SEO?

With so many aspects of SEO to track, from digital metrics to overarching strategy, technical tweaks, and more, optimising is no small feat.

As there’s so much plate-spinning in the organic search industry, often basic principles, such as URL structures and their slugs go under the radar. In this guide, we’ll tell you how you can use these crucial pieces of your website’s build to strengthen your strategy, as well as some top tips to get you started.

Contact Us

What is a URL Slug and why is it important?

Magnifying glass examining an SEO-friendly URL

Essentially, the ‘slug’ part of a URL refers to the section following the backslash (“/”) – which identifies the specific page or post.

Every slug across your webpage has to be unique, as it offers search engines and users context clues regarding its content. Not all pages have slugs, though, such as a homepage URL or website domain name – but all other pages will have one automatically generated.

Of course, these automated slugs aren’t going to be as optimised for SEO as the ones you could produce yourself – which is what we’ll touch on later.

Even though they are tiny pieces of information, URL slugs significantly impact your SEO as a whole. Here’s how:

  • Search engines require clear and concise content to fully understand the data it links to, having a similarly clear and short URL slug can help them comprehend your page.
  • It also helps users comprehend your page, improving the user experience and boosting click-through rates as they know your page will be useful to them.
  • Automated URLs stuffed with numbers and other symbols aren’t useful, so optimising your slugs with keywords and other target terms can help you rank.
  • As users understand what the site is about, they’re more inclined to share it around, which, in turn, improves social sharing.

Why is it called a ‘slug’?

The term ‘slug’ comes from journalists using short descriptions to summarise a story in progress. It uses few words to clearly describe the intent and topic of the story. So, it has now been applied to the part of the URL referred to as a ‘slug’ by people in the world of web development and SEO.

How to create the best URL Slugs for SEO

Optimising a URL for SEO

You don’t need to be overly strategic or complicated when creating slugs. Opting for simple and scannable is your best bet, with the following tips designed to improve your URL’s accessibility readability and SEO factors as a whole.

1. Use the “-” symbol

A hyphen will ensure that your URL slug is crisp and clean – without the use of a ‘space’. It can be tricky to put long-tail keywords, especially questions or phrases, into a URL without natural breaks, but URLs aren’t permitted to have them.

So, to stop browsers from substituting them with a percentage symbol, a hyphen fits the bill perfectly. They’re also better than the likes of underscores, as hyphens make it easier for the crawlers to crawl and index the page.

2. Keep your slugs short

It is easier for readers to remember URLs with short and clear slugs. Not only because they make it easy for them to understand what content is available on each page, but they also help search engines crawl and ‘comprehend’ the content.

We recommend keeping your URL slug length between three and five words.

3. Match slugs to headlines

For informative content such as blogs, listicles and articles, your slug should, ideally, match the content title itself.

Of course, it doesn’t have to be a word-for-word match (the shorter the better) but as long as the intent and keyword are there, you’re golden.

You can only use the specific slug once, so make sure it accurately matches the headline it’s attached to and that you’re happy with it being attributed to the specific content.

4. Avoid dating your slugs

It can be frustrating for users to see a date from a previous year in your URL slug. Even if your content is technically correct and evergreen, adding a date can quickly make it appear stale. Unless you’re frequently updating that piece, adding a timestamp can clog up your URL and boot out opportunities for keywords – so leave them altogether.

5. Use lowercase letters

Duplication and display issues are common with URLs. Similarly to spaces, uppercase letters are a prime suspect for causing issues with 404-errors and even duplicate content, so make sure everything is in easy-breezy lowercase.

6. Don’t use special characters

Using special characters (such as # or !) is not the best practice as search engines can’t recognise them and will just convert them to ‘%’. However, they do recognise hyphens, so as we mentioned, hyphens are the best bet for separating the words in your URL slug.

7. Update old slugs

If you’ve got a plethora of older, creaky slugs, it might be a good idea to update them to a clearer meaning with improved formatting.

Slugs, however, should not be constantly updated. Your search engine rankings can be negatively affected if you do this too often, so start sparsely on lower-ranking pages. From here, you can actively monitor your results and decide whether it’s worth taking a gamble on your newer ones.

Just remember: once you’re slung your slugs, make sure you do what you can to keep them the same for as long as you can!

What does Google have to say?

Straight from the experts themselves, Google says:

  • Use the relevant keywords
  • Keep it short and clear
  • Use hyphens
  • Accurately reflect what the page is about
  • Words within a URL are a ranking factor
  • The crawlers use a slug to gain an understanding of the page’s content

Slugs deserve love, too!

URL slugs have fallen by the wayside for years, known as nothing more than a way to tell visitors your page name.

But understanding how to improve your URL slugs can, in turn, help you improve your SEO results – with these clever bits of code providing search engines with crucial information to organise and display your website.

So don’t neglect your slugs. Show them you care and they’ll show their thanks in those ranks.

If you’d like a bespoke SEO strategy created for your unique business – our experts can help.

Contact Us


FAQs

Answered by Jamie Beatty

How do I check I have not made a duplicate URL?

WordPress is one of the most common CMS. These platforms won’t allow you to create a duplicate URL. It will flag or change the URL so that duplicates can’t be made.

What other punctuation can google crawlers understand?

Crawling tools will pick up punctuation in URLs. The best practice is to use the hyphens where possible and avoid underscores.

What will changing a slug do to my internal linking?

Changing the URL slug after the site has been set live will cause the old URL to show as a 404 error- the page will no longer exist. You will need to implement a redirect from the old page to the new page. We would want to also update the new internal links to the new URL. Avoids slow loading times.

How do I change URL slugs?

This is done in WordPress. In the website CMS, you can change the URL under the edit settings of each page. This should be done before the page is set live.


Deeper insights