Loading Slug Generator...
Please wait a moment

How to Generate URL Slugs - Step by Step Guide

Step 1

Enter Your Text

Start by entering the text you want to convert into a URL slug:

•
Blog post titles: Convert article headlines to URL-friendly slugs
•
Product names: Create clean URLs for e-commerce product pages
•
Category names: Generate slugs for categories, tags, and taxonomies

Example: Original Text

Here's a typical blog post title:

How to Learn JavaScript in 2025: A Complete Guide for Beginners!

Step 2

Choose Separator & Settings

Customize how your slug is generated with these SEO settings:

•
Hyphen (-): the usual choice; search engines read it as a space between words
•
Underscore (_) or dot (.): for systems that ask for them, such as file names or internal keys
•
Lowercase: on by default; untick it to keep capital letters as typed

Example: Generated Slug

The URL-friendly slug:

how-to-learn-javascript-in-2025-a-complete-guide-for-beginners
Step 3

View Slug Information

Under the slug you get two numbers to help you trim it:

•
Length: how many characters the slug has
•
Word count: how many words sit between the separators
Step 4

Copy or Download Your Slug

When the slug looks right, take it with you:

•
Copy: puts the slug on your clipboard, exactly as shown
•
Download: saves the same text as slug.txt
•
Paste it in: the permalink field in WordPress or Ghost, or the front matter of a Hugo or Jekyll post

Frequently Asked Questions

What is a URL slug?

It is the readable last part of a web address that names one page. In example.com/blog/how-to-learn-javascript, the slug is how-to-learn-javascript. Most blogs and shops build it from the page title, which is exactly what this page does.

Should I use hyphens or underscores?

Hyphens, in almost every case. Google treats a hyphen as a space between words, while an underscore can join two words into one, so my_new_post may be read as a single word. Underscores and dots are here for systems that ask for them, such as some file names or internal IDs.

What happens to accents, symbols and emoji?

Accented Latin letters lose the accent: Crème Brûlée becomes creme-brulee, and letters like ß, æ, ø and ł are written as ss, ae, o and l. Punctuation, symbols and emoji are not kept; each run of them, like spaces, turns into one separator, so Node.js / React becomes node-js-react. Apostrophes are the exception and simply vanish, so Don’t Stop gives dont-stop. Numbers are kept digit for digit, for example 8901240544102066246 or 00501.

What about Chinese, Japanese, Russian or other non-Latin text?

Those letters are kept as they are, so 東京 タワー becomes 東京-タワー and Привет мир becomes привет-мир. Modern browsers show such slugs fine, but the raw URL carries them percent-encoded (each character turns into several %XX codes). If you need a plain ASCII slug, write the title in Latin letters first; this page does not transliterate other scripts.

How long should a slug be?

Short enough to read at a glance. Three to five meaningful words is a good target, and dropping filler words such as a, the and for usually helps. The panel under the slug shows its length and word count so you can trim it, and Google’s URL structure guide is worth a look for the reasoning.

Is my text sent anywhere?

No. The slug is built in your browser as you type. Nothing is uploaded and nothing is kept, so a reload starts with an empty editor.

Further reading: Google's URL structure guide. To pull apart a full address, try the URL Parser; to add parameters to one, the Query String Builder.