How to Define Best Permalink structure
The default permalink structure for wordpress is something like this:
https://binarynote.com/?p=123, where “123? is the internal ID of the post. I totally disagree with that structure and I’m not the only one in this world who thinks meaningless and useless for SEO purposes.
This permalink structure doesn’t help in any ways your rankings or your placing in the SERPs. This is obvious because one of the most important rules for SEO is having the keywords in your URL/titles. Honestly, I don’t understand why they choose that as default, but that’s not so important.
The pretty structure is something like this:
https://binarynote.com/2010/10/27/some-post-name. Now, the big question is: which permalinks structure is the best one? I’ll let you decide that, but, for me, one thing is for sure: the post name has to be in the URL. WordPress comes with few options for the Permalink structure :
- Day and name, which is actually ‘year, month, day and name’. This helps the reader too as it’s like searching through the blog archive. You have the year, the month, the day, so you can easily find the post.
- Month and name, which is almost the same with the first option just that the day is missing
- Category and post name, for instance
https://binarynote.com/some-category/some-post-name. This format is used on a lot of new blogs lately. Some say that the category name is relevant to the post name, and hence improve SEO.
- Post name, meaning just binarynote.com/some-post-name. This 4th one is used on a lot of blogs as well.
WordPress offers you the possibility to go even further with your imagination, using the structure tags in your permalinks to create a custom Permalink structure. According to ‘codex’, these are the structure tags you can use in your permalinks settings page:
- %year% – The year of the post, four digits, for example 2004
- %monthnum% – Month of the year, for example 05
- %day% – Day of the month, for example 28
- %hour% – Hour of the day, for example 15
- %minute% – Minute of the hour, for example 43
- %second% – Second of the minute, for example 33
- %postname% – A sanitized version of the title of the post (post slug field on Edit Post/Page panel). So “This Is A Great Post!” becomes this-is-a-great-post in the URI (see Using only %postname%)
- %post_id% – The unique ID # of the post, for example 423
- %category% – A sanitized version of the category name (category slug field on New/Edit Category panel). Nested sub-categories appear as nested directories in the URI.
- %author% – A sanitized version of the author name.
You can use ‘-’ or ‘/’ to separate them, eg: /%category%/%postname%-%post_id%/
This isn’t a SEO blog so I’ll let you decide which one is the best permalink structure for your blog. I personally support having post name and id and nothing else. Why? It’s because your post name will contain your keywords.
Therefore, if the URL is short, the keyword density will be high(the concept is called relative weight of keywords). I don’t encourage having only the post name in the title, and here’s why, if you do that, the rewrite rules may make it impossible to access pages such as your stylesheet or the /wp-admin folder.
That’s why it’s best to include some numeric data in the post, for instance the post ID. This will prevent you from having two posts with the same URL (I know you wouldn’t name two posts the same, but you might have two posts with the same name in different categories, etc … you never know).
One thing I forgot to mention is that if you already made some posts and published them with the faulty structure, there is a plugin that will help you redirect the old URLs to new ones. Dean’s Permalink Structure Migration or if you are using Yoast SEO then use 301 redirect in advance tab..