Kebab-Case and URL Slugs: How to Write Clean Web Addresses
A good slug is short, lowercase and readable. Hyphens, not underscores or spaces, are the right separator.
By the Universal Case Converter Team
What a slug is
A slug is the part of a web address that identifies a page in human-readable words. In the address example.com/blog/kebab-case-and-url-slugs, the slug is kebab-case-and-url-slugs. The word comes from newspaper production, where a slug was a short name for an article in the production system. Content management systems adopted the word for the readable part of a URL.
A slug is usually made from the title of the page. The process is mechanical: lowercase the text, remove punctuation, replace spaces with hyphens and shorten the result. The outcome is called kebab-case, because the words are skewered on hyphens. A converter can do most of this in one click, but you still decide which words to keep.
Why hyphens, not underscores or spaces
A space is not allowed in a URL. When a space appears, browsers replace it with the code %20, which makes the address long and ugly: my%20page%20title. Underscores are allowed, but search engines treat them differently. Google's guidance on URL structure recommends using hyphens to separate words, and not underscores, because hyphens are treated as word separators.
Google has long said this explicitly in its documentation about URL structure: it recommends hyphens over underscores. In practice, a slug with underscores is not a disaster, but there is no reason to take the risk when hyphens are available and readers find them easier to scan. The same convention is used by most large websites and by the default settings of popular CMS platforms.
Why lowercase
The scheme and the host name of a URL are not case sensitive: HTTPS://EXAMPLE.COM and https://example.com lead to the same site. The path is another matter. According to the URL standard RFC 3986, the path is case sensitive, and many web servers, especially those on Linux, treat /About and /about as different addresses. A mixed-case slug can therefore produce two URLs for one page, or a broken link when someone types the address in the wrong case.
The safe policy is simple: use only lowercase letters in slugs. Then there is only one correct spelling, links are easy to copy, and redirects are easy to write. If an old site used capitals, set up permanent redirects from the old addresses to the lowercase ones.
How to turn a title into a slug
Take the title "10 Tips for Better Sleep: A Beginner's Guide!" Lowercase it: "10 tips for better sleep: a beginner's guide!". Remove punctuation: "10 tips for better sleep a beginners guide". Replace spaces with hyphens: "10-tips-for-better-sleep-a-beginners-guide". That is a valid slug. Most people then shorten it, for example to "better-sleep-tips".
Short slugs are easier to read and share. Remove words that add nothing, such as a, the and of, if the meaning stays clear, and keep the words that describe the page. Keep the numbers when they carry meaning. Avoid dates in the slug unless the page is tied to a date, because a date in the address makes updated content look old.
Accents, umlauts and other alphabets
URLs can contain non-English letters, but they are percent-encoded when they are sent, which makes them unreadable when copied into some programs. Many sites therefore transliterate letters: ä becomes a or ae, ö becomes o or oe, ü becomes u or ue, ß becomes ss, é becomes e and ñ becomes n. German sites usually follow the convention of ae, oe, ue and ss.
Sites in languages that do not use the Latin alphabet face a choice between keeping native characters in the slug and using a Latin transliteration. Both work, and modern browsers show the native characters in the address bar. A transliteration is easier to share in plain text. Whatever you choose, apply it everywhere. Note that the case converter on this page keeps accents; remove or transliterate them before you use the text as a slug.
Common slug mistakes
The first mistake is changing a slug after the page has been published, because every link and every saved bookmark to the old address breaks. If you must change it, add a permanent 301 redirect. The second mistake is a slug that repeats the same words, such as /blog/blog-post-about-blogging. The third is a slug with special characters such as & or ?, which have meanings in URLs. The fourth is a very long slug that copies the whole title.
Another frequent mistake is keeping the default of your tool, which may produce an address with numbers or an ID only. A readable slug helps people decide whether to click a link that is shared in a message or printed, and it tells search engines what the page is about, although the effect on ranking is small.
Quick workflow with the converter
Paste the title into the converter and click kebab-case. The tool splits the text at spaces and punctuation and joins the words with hyphens in lowercase. It also splits at changes from lowercase to uppercase, so a title in camelCase is split into words. Then shorten the slug by hand, replace accents if needed and check that the result reads naturally.
Because the tool works line by line, you can paste a whole list of titles and get a list of slugs at once. This is useful when you plan the structure of a new site, or when you prepare a spreadsheet for a bulk import.
Turn any title into a clean kebab-case slug with the free case converter.
Open the case converter