Why do some websites add "Slugs" to the end of URLs?

Dave Webb picture Dave Webb · Sep 6, 2008 · Viewed 43.6k times · Source

Many websites, including this one, add what are apparently called slugs - descriptive but as far as I can tell useless bits of text - to the end of URLs.

For example, the URL the site gives for this question is:

https://stackoverflow.com/questions/47427/why-do-some-websites-add-slugs-to-the-end-of-urls

But the following URL works just as well:

https://stackoverflow.com/questions/47427/

Is the point of this text just to somehow make the URL more user friendly or are there some other benefits?

Answer

Espo picture Espo · Sep 6, 2008

The slugs make the URL more user-friendly and you know what to expect when you click a link. Search engines such as Google, rank the pages higher if the searchword is in the URL.