The address or URL of each post or page is known as a permalink. A shortlink is a shorter version of that permalink. And a slug? It’s the part of the permalink that identifies the specific post or page. Here’s a five minute guide to understanding WordPress permalink styles, shortlink options, and slug optimization.
1. Don’t change your permalink style without help.
Your permalink style defines whether your post URLs are http://yoursite.com/post-name/ or http://yoursite.com/2013/10/post-name/, etc.
If you’re just starting out with WordPress.org, choose something other than the default permalink style (see The First 5 WordPress Settings I Change). Otherwise, don’t change permalink styles unless you have technical assistance—you may break old links. (Read more about Pretty Permalinks.)
2. The slug is the part of the permalink that identifies your post or page.
WordPress automatically creates a slug that has hyphens in place of spaces between the words of your post or page title.
If extra words are automatically disappearing from your post slug, you probably have a plugin like WordPress SEO by Yoast installed. You can disable this by going to SEO, Permalinks, and unchecking “remove stop words”—however, removing articles like a, an, the is actually good SEO practice. (Check out SEO Tips for Beginners at Small is Enough.)
3. Your post slug doesn’t have to be the same as your post name.
Your post name may be long, but your post slug doesn’t have to. You can edit your post slug to be more user and SEO friendly. For example, the slug for this post is wordpress-permalinks-shortlinks-slugs even though the title is much longer: “The 5 Minute Guide to WordPress Permalinks, Shortlinks, and Slugs”.
4. Don’t change your post or page slug after you’ve published your post.
If you change your post slug after a post is published, the post share/like counts will be reset, and any previous links to the post likely broken.
If you need to change a post or page slug after it is published, be sure you know how to create .htaccess redirects or are using a plugin like Redirection that will automatically redirect all renamed post slugs.
5. Shortlinks are your friend, especially on Twitter.
If you’re using Jetpack, deactivate the WP.me shortlinks so you can use the built-in WordPress shortlinks which will direct people to your post even if it has changed. WordPress shortlinks are based on the post’s numerical ID that doesn’t change. So for example, this post’s shortlink https://gretchenlouise.com/?p=11469 will always direct to the post or page with the ID 11469, even if I change the post title or page slug.
When you’re Tweeting a post, Twitter or your Twitter client will usually shorten the link again so that it can fit in less than 140 characters. If you’re scheduling Tweets before a post is published (with Click to Tweet, for example), be sure to use the WordPress shortlink in case you change the post slug. If the date is in your permalink, you’ll want to use the shortlink or schedule the post before you schedule Tweets or you could end up with a broken link once again.
Got more than 5 minutes?
Read more about permalinks and slugs: