For this post we’re going to be taking look at the optimal permalink and URL structures for wordpress. There are a lot of different options, and there isn’t a one size fits all answer, however there are definitely better and worse choices you can make.
Out of the box wordpress is configured like this
This really isn’t a permalink structure, it’s a parameter based format with “123” being the post number. While all major search engines can crawl and index this it’s generally not an optimal setup. From an SEO perspective you miss the opportunity to give the search engines some keywords, and from a user experience you miss the opportunity to entice them with an information scent that they are on the right track. For example lets assume you were looking for hotels in Kentucky which URL gives you a clue you might find the information your wanted on the page:
Another common implementation involves putting some or all of the date in the post URL, like these two examples:
I know longer recommend using dates in your urls unless you are publishing news. Google will extract the datess and add them to the SERP’s. Old dates get less click thrughs
The first example creates a heirarchy based on year, day, month, this is really unneccesary in most situations. If you are going to add words/numbers to your url’s they should have a reason and/or keyword value. Unless the date is important to the majority of the keywords or terms you are trying to rank for, they are decoration. In fact if you publish a lot of evergreen content, having the date may work against you. Many users have a bias for “new” content, and are more likely to click something newer over something older (I use date based hooks to stop showing the date in the text on older posts). In the second example you aren’t creating a directory structure but you are including the date. This is less dangerous, but if you change your production schedule and the date of publication, you may create some 404 errors if posts were interlinked, so again I’d avoid using it, unless you have a really good reason.
Another common implementation involves categories like this:
On the surface this implementation looks ok, but there are some downsides, for example if you like to put posts in two categories your post can exist at two URL’s like:
The problem is BOTH url’s will work, the second is wordpress chooses which is the “primary” one, not you. Another disadvantage is if you decide to rename/consolidate/change your categories you’ve got a massive 301 project on your hands. However one advantage of this set up is that you can exclude some directories via robots.txt file. A variation of this technique is :
Unless you are going to have a massive number of posts, or posts with very similar titles (you may have 15 different apple pie recipes for example) I’d opt for the keyword over the post number.
One last combination I’d like to look at is :
The advantage of this configuration is it’s very short and has keywords, however if you have more than one post with the same name, wordpress will automatically add a number onto the end like this:
This isn’t horrible but something to keep in the back of your mind. Something to be aware of using this strategy, you won’t be able to exclude files by directory in the robots file, you’ll need do it by single post or use the meta data. One additional bit of information I’d like to throw into the mix is consideration for google news. If you ever think there might be the remote possibility you’ll want to get into google news add a unique 3 digit number into the structure, I prefer to append the post number after the page title (words at the front have more KWD value so put the place holder numbers at the end):
You could use the date instead of the number, just be sure to consider how changing publishing date can affect other links (like if an embargo is broken and you decide to publish early too, linked posts might be broken).
My recommendations are, post title & post number followed by category & post title, here are few other points to keep in mind:
- Try to stay in the 3-5 word range whenever possible, including the category
- Eliminate stop words whenever possible
- use your URL to incorporate KWD variations
PS: having done more than my fair share of .asp and .html to php migrations I always leave the file extensions off, there are workarounds, but I have a strong personal bias to do something once and do it right …