What Is Slug?
A slug is the human-readable portion of a URL that identifies a specific page, typically the final segment of the path after the last slash. In the address example.com/blog/my-first-post, the slug is my-first-post. Slugs are usually lowercase words joined by hyphens, describing the page’s content in a form both people and search engines can read.
- In
https://example.com/blog/my-awesome-article, the slug ismy-awesome-article— the last, editable part of the path that names the page. - Google recommends readable words in URLs, so a descriptive slug like
/aviationbeats an ID-driven address such asindex.php?topic=42. - Words in a slug should be separated by hyphens, not underscores, because Google uses hyphens to tell concepts apart.
- Content systems like WordPress auto-generate a slug from the page title, but the slug can and often should be edited to be shorter and cleaner.
How a Slug Works
Break a URL into pieces and the slug is the last meaningful one. In https://example.com/blog/my-first-post, the scheme is https://, the domain is example.com, /blog/ is a folder, and my-first-post is the slug — the part that identifies this specific page rather than the section it lives in. The word borrows from newspaper production, where a slug was the short internal name editors used to refer to a story while it moved through the presses. On the web it plays the same role: a compact, human-friendly handle for one page.
A slug is worth caring about because it is the part of the URL you actually choose, and Google is explicit about what a good choice looks like. The URL structure guidance recommends “readable words rather than long ID numbers,” and it recommends hyphens over underscores so that separate concepts read as separate words. A slug is exactly where those rules apply. /aviation and /summer-clothing are slugs that obey them; /index.php?topic=42 and /summer_clothing are the counterexamples Google warns against.
Most content management systems generate a slug automatically from the page title. WordPress, for instance, turns a post titled “My Awesome Article” into the slug my-awesome-article and exposes it as an editable field. As WordPress’s own documentation describes, the slug is the customizable end of the permalink — the full, permanent URL — and it is meant to give a “user-friendly description” of the page. That auto-generation is a convenience, not a mandate: a title-derived slug is often longer than it needs to be, and trimming it before publishing is one of the cheapest wins in on-page SEO.
Example of a Slug
Google’s URL structure documentation provides the reference case, because it shows the slug decision as a direct before-and-after. Google’s recommended, readable URL is:
https://example.com/wiki/Aviation
Here wiki is the folder and Aviation is the slug — a single, legible word naming the page’s subject. Google contrasts this with the form to avoid:
https://example.com/index.php?topic=42&area=3a5ebc944f41daa6f849f730f1
The second address has no slug at all. The page is identified by numeric and hexadecimal IDs passed as URL parameters, which carry zero meaning to a human and no topical signal to a crawler. Both URLs can resolve to the identical article; the only difference is whether the page announces itself in words or hides behind machine identifiers.
The WordPress workflow shows the same principle in the tool most publishers actually use. Give a post the title “10 Best Tips For Writing Great Blog Posts,” and WordPress will propose the slug 10-best-tips-for-writing-great-blog-posts. It is technically valid — lowercase, hyphenated, readable — but longer than the page needs. Editing it down to blog-writing-tips keeps everything Google asked for, shortens every link to the page, and reads more cleanly in a search result. That is the whole craft of a slug: take the readable-words-and-hyphens rule Google states, and spend a moment making the result as short and honest as it can be before the URL becomes permanent.
The temptation with slugs is to cram the whole target keyword phrase in and call it optimized, but the property that actually matters is that you set it once and never change it. A slug is a permanent identifier baked into every link and share of that page. When people rename a slug to chase a keyword, they either break the old URL or bolt on a redirect that leaks a little equity every hop. Write a short, honest, hyphenated slug at publish time — two or three words that name the page — and then leave it alone. Auto-generated slugs from a long title are the usual mess: /10-best-tips-for-writing-great-blog-posts-in-2026 should just be /blog-writing-tips. Trim it before you hit publish, because after publish, every edit has a cost.
Frequently Asked Questions
What is a slug in a URL?
example.com/blog/my-first-post, the slug is my-first-post. It is meant to describe the page’s content in words a person and a search engine can both read.How should I format a slug?
/blog-writing-tips is cleaner and clearer than /blog_writing_tips or a numeric ID.Should I change a slug after publishing?
Is the slug the same as the URL?
The Bottom Line
A slug is the readable tail of a URL that names a single page, normally the last path segment, spelled as short lowercase words joined by hyphens. It exists to make an address legible to people and search engines instead of leaving it as an opaque ID. Write it clearly and briefly at publish time, keep it hyphenated, and treat it as permanent — because everything that links to the page depends on it not moving.
Sources
- Keep a simple URL structure — Google Search Central
- Edit a page or post link (permalinks and slugs) — WordPress.com
Rank & Cash — the weekly SEO breakdown
One practical teardown a week on ranking in search and getting cited by AI. No fluff.
