What is a URL Slug?

A URL slug is the part of a web address that identifies a specific page in human-readable form. It comes after the domain name and any directory path, and it describes the page content using lowercase words separated by hyphens.

https://quickmicrotools.com/blog/slug-generator-guide
Domain
Path / directory
Slug (this page's identifier)

The term "slug" comes from newspaper typesetting — a short label used to identify a story in production. In web development, it serves the same purpose: a concise, URL-safe label for a piece of content.

Generate a clean, SEO-friendly slug from any title instantly — free, no sign-up.

Open Slug Generator →

Why Slugs Matter for SEO

URL slugs are a confirmed on-page SEO factor. Google reads the URL of a page to understand its topic — and a clear, keyword-rich slug reinforces the relevance signal that your title tag and content already send.

✓ SEO Rule

Include your primary keyword in the slug. Keep it short. Use hyphens. Never change a slug after a page is indexed without setting up a 301 redirect.

Good vs Bad Slugs

Here's how the same page title translates into slugs of different quality:

✗ Bad — spaces
how to calculate percentage
✓ Good
how-to-calculate-percentage
✗ Bad — uppercase
How-To-Calculate-Percentage
✓ Good — lowercase
how-to-calculate-percentage
✗ Bad — underscores
how_to_calculate_percentage
✓ Good — hyphens
how-to-calculate-percentage
✗ Bad — too long
how-to-easily-calculate-a-percentage-with-examples-online
✓ Good — concise
calculate-percentage
✗ Bad — special chars
what-is-bmi?-how-to-calculate!
✓ Good — clean
what-is-bmi-how-to-calculate

7 Slug Best Practices

🔡

Use lowercase only

URLs are case-sensitive on most servers. Always use lowercase to avoid duplicate content issues from URL variants.

Use hyphens, not underscores

Google treats hyphens as word separators. Underscores join words together, reducing keyword matching effectiveness.

✂️

Keep it short

Aim for 3–5 words. Remove filler words like "a", "the", "and", "in", "of" unless they're part of the keyword.

🎯

Include your keyword

Put the target keyword at the start of the slug when possible. It carries more weight near the beginning of the URL.

🚫

No special characters

Avoid ?, #, %, &, spaces, or any character that needs URL encoding. Stick to letters, numbers, and hyphens.

🔒

Never change without a redirect

Once a URL is indexed, changing the slug without a 301 redirect destroys accumulated backlink equity and rankings.

🌐

Use ASCII characters

For non-English content, transliterate accented characters (é → e, ü → u) rather than using encoded Unicode in URLs.

Hyphens vs Underscores

This is one of the most commonly misunderstood slug rules — and getting it wrong has a direct impact on search rankings.

Google's John Mueller has confirmed that hyphens are treated as word separators, while underscores join words together. This means:

If your target keyword is "word counter" (two words), the hyphenated version matches the search query directly. The underscored version does not match either word individually.

⚠️ Important

Always use hyphens in URL slugs. The only exception is if your CMS or framework enforces underscores — in which case this is a platform limitation, not a choice.

Should You Remove Stop Words?

Stop words are common words like "a", "an", "the", "and", "in", "of", "for", "to", "with". The traditional SEO advice was to remove them from slugs to keep URLs short. The current guidance is more nuanced.

As a rule of thumb: read the slug aloud. If it still makes sense without the stop words, remove them. If it sounds wrong or changes the meaning, keep them.

Slugs in Popular CMS Platforms

Most content management systems auto-generate slugs from your page title. Here's how the major platforms handle them:

PlatformAuto-generateDefault separatorWhere to edit
WordPressYesHyphensPost editor → Permalink field
WebflowYesHyphensPage settings → Slug field
ShopifyYesHyphensProduct/page editor → URL handle
GhostYesHyphensPost settings → URL field
WixYesHyphensPage SEO settings → URL
Custom HTML/JSNoManualFile name / router config
⚠️ Warning

Auto-generated slugs often include stop words and are too long. Always review and manually edit the auto-generated slug before publishing — especially for pages targeting specific keywords.

How to Generate a Slug Online

Creating a clean slug manually means remembering all the rules every time. Our free Slug Generator automates the entire process:

  1. Open the Slug Generator Tool.
  2. Paste or type your page title or heading.
  3. The tool instantly converts it to a clean slug — lowercase, hyphens, no special characters.
  4. Review and optionally shorten by removing stop words.
  5. Copy the slug with one click.
  6. Paste it into your CMS's permalink or URL field.
💡 Example

Input: "How to Calculate Body Mass Index (BMI) — Step-by-Step Guide 2026"
Output: how-to-calculate-body-mass-index-bmi-step-by-step-guide-2026
Shortened: calculate-bmi-guide

Generate a clean SEO-friendly slug from any title — free, instant, no sign-up required.

Open Slug Generator →

Frequently Asked Questions

A URL slug is the human-readable part of a URL that identifies a specific page. In https://example.com/blog/what-is-a-slug, the slug is "what-is-a-slug". Slugs are lowercase, use hyphens instead of spaces, and contain no special characters.
Yes. Slugs are a confirmed ranking factor. Including your target keyword in the slug signals relevance to search engines. Descriptive slugs also improve click-through rates in search results because users can understand the page topic from the URL alone.
Always use hyphens. Google treats hyphens as word separators, so "word-counter" is indexed as two words. Underscores join words together — "word_counter" is treated as the single word "wordcounter", which reduces keyword matching effectiveness.
Keep slugs as short as possible while remaining descriptive — typically 3 to 5 words. Remove stop words like "a", "the", "and". "calculate-percentage" is better than "how-to-easily-calculate-a-percentage-online".
You can, but only if you set up a 301 redirect from the old URL to the new one. Without a redirect, the old URL returns a 404 error — losing all backlinks, rankings, and traffic that the original URL had accumulated. Always implement a 301 redirect when changing a published slug.

Conclusion

A good URL slug is short, keyword-focused, lowercase, and hyphen-separated. It takes ten seconds to write a good one — and those ten seconds can make a measurable difference to how your page ranks, how users perceive your site, and how link equity accumulates over time.

Use our free Slug Generator to convert any title into a clean, SEO-ready slug automatically — no more manually removing special characters or converting spaces to hyphens.

Generate clean, SEO-friendly slugs from any title in one click — free, browser-based.

Open Slug Generator →

Related Tools