The post slug is the user friendly and URL valid name of a post. Most common usage of this feature is to create a permalink for each post. WordPress automatically generates post slugs from a post’s title.
WPBeginner Glossary – Post Slug
Example post permalink:
The slug for that post is
Slugs are also used for post types, categories, tags, etc. Like post and page slugs, this is usually for creating URL friendly versions of these items.
The post slug, category slug, tag slug, Page slug, etc., are set by the Permalink structure in WordPress, customizable on self-hosted versions of WordPress through Settings > Permalinks
About The Word
Named for the lead used in typesetting. The lead was lowered into a heated container that melted the metal for pouring into forms like the Linotype typeset masters to form letters, words, or sentences as the technology improved. It also became the term for the space between paragraphs. The point system of measurement still used today in print and web design came from those days where typesetting was set in strips of 6-point led, and one line of Linotype equaled one piece of lead. Connecting the past with the present, the post slug is the line, label, or name of the web page when WordPress or a CMS is setup to display it in word form rather than numbers or conditionals.
In WordPress, the slug is a cleaned up set of the words used in the post, Page, category, or other pageview title. WordPress automatically cleans up punctuation and sets the words to lowercase so that Sally’s Pretty Dresses!” will become
To edit the slug of a post or Page, on the Edit Screen of that post or Page, click the Edit Slug or Edit next to the post title URL.
Some users edit long titles to shorten the permalink slug such as a post title “This is the Story, a Long Story, of How I Learned that WordPress was the Only Content Management System for Me” could be easily shortened to “WordPress is Only CMS for Me.” Others will edit the slug to a more SEO-friendly phrase the uses only the most important and relevant keywords, such as “WordPress CMS” for the above title.
Once published, the post slug should not be changed as it will results in a Page Not Found Error.
The slug for categories, tags, authors, and other generated pageviews in WordPress are set in the WordPress Theme through the use of template tags that automatically generate the pageview title, often based upon their names set through Posts > Categories or by the Author Username or Display Name settings.
For More Information
- WordPress Post Slug: Use It Efficiently – Daily Blog Tips
- Understanding Permalinks and Slugs in WordPress | Blogger to WordPress User Guide
- A Straight-Forward Guide To WordPress Slugs – Elegant Themes Blog