When you publish a page or an article, its address can be an unreadable mess like /page?id=4821, or something clean and human-readable like /how-to-make-a-slug. The second form is called a slug, and it's the backbone of a good URL. Let's break down how to build one properly.
What a slug is
A slug is the part of a page's address derived from its title: lowercase Latin letters, digits, and hyphens instead of spaces. For example, the title "How to Open a HEIC File on Windows" becomes how-to-open-heic-on-windows.
Why slugs matter
- SEO. Search engines and users see keywords right in the address — that helps both ranking and click-through rate in search results.
- Readability. A good link tells you what the page is about before you even click it.
- Reliability. An address with no spaces or special characters doesn't break when pasted into messengers or emails.
Rules for a good slug
- Use lowercase letters only.
- Replace spaces with hyphens (not underscores).
- Transliterate non-Latin characters into Latin letters where needed.
- Optionally drop filler words, but don't overdo it.
- No punctuation, brackets, or special characters.