WordPress Permalink Structure

August 1, 2008 by  

Since we want to create a well-structured web-site, we need to set WordPress up so that it creates SEO friendly URLs for your posts.  To do this, we need to edit the Permalink options.

Literally speaking, a permalink is link that doesn’t change.  e.g. when you write an article for your website, it is given a URL.  This URL is what you will link to if you reference your article somewhere else on the web.  You certainly do not want the URL to change – it needs to be permanent.  Get the idea?

Permalinks are the permanent links to your articles.  In WordPress, we can configure how those will look.

To change the permalink structure for your site, click on the Settings menu, and select Permalinks:

permalinkmenu


You will be taken to the Permalink screen that gives you various options for permalink structure.  Here are the first 4 with examples of what your links will look like:

http://mydomain.com/blog/?p=123

http://mydomain.com/blog/2008/08/01/sample-post/


http://mydomain.com/blog/2008/08/sample-post/


http://mydomain.com/blog/archives/123



We are interested in the 5th type of permalink – Custom, because it allows us to define how we want the links to be organised.  There are a number of variables you can use to define your permalink structure:

%year%

The 4 digit year of the post
%monthnum%
Month of the year
%day%
Day of the month
%hour%
Hour of the day
%minute%
Minute of the hour
%second%
Second of the minute
%postname%
The name of the post (words separated by a dash)
%post_id%
The unique ID number of the post
%category%
The category of the post.
%author%
Author name.

You can combine these variables into a custom permalink structure.  Most of them are not very useful for an affiliate site.  What is useful to use is the %postname% and %category% variables.

Select , and enter the following:

/%category%/%postname%/

Scroll down and save your changes.  You can ignore the optional settings at the bottom.  Now, your posts will look something like:

http://mypetshop.com/dogs/beagle

Where beagle is the name of the post, and dogs is the category you posted it in.

Print This Post Print This Post

Related Articles

  • Things you need to know about Permalinks - Permalinks are a great way to optimize your blog post URLs.  If you read my article on WordPress Permalinks,  you may be using the same permalink structure that I use, namely this one: /%category%/%postname%/ With this type of permalink structure, your post URLs will look like this: http://affiliate-minder.com/wordpresstutorials/install-wordpress-theme/ This is an actual URL from this site.  See that the
  • Manual Upgrade of WordPress - It has happened a few times to me.  The automatic upgrade plugin for WordPress hasn’t worked.  The last time this happened was with WordPress release 2.6.1. and it happened on all of my blogs.  Is it a hosting issue, or a plugin issue?  I am not sure, but what I am sure about is that
  • Adding a Feedburner Subscription Box to your WordPress Site - Feedburner is a great free service (now owned by Google).  It allows people to subscribe to your feeds, and will even email your subscribers for you whenever you post new material to your blog.  It doesn’t matter whether you post 1 or 100 new articles to your site in any given day – Feedburner will
  • WordPress posts & pages – what are the differences? - WordPress gives you the option of using a post or a page for your content. There is often a lot of confusion anongst WordPress users as to which one they should use and why. Bookmark on DeliciousDigg this postRecommend on FacebookBuzz it upshare via RedditShare with StumblersTweet about itBuzz it upSubscribe to the comments on
  • WordPress Tags – Uses and Abuses - WordPress tags are often abused and the consequences can be bad. Learn to use WordPress Tags effectively. Bookmark on DeliciousDigg this postRecommend on FacebookBuzz it upshare via RedditShare with StumblersTweet about itBuzz it upSubscribe to the comments on this post
"The Money Is In The List"

AWeber proves it to thousands of businesses every day.

Learn how email marketing software
can get you more sales, too.

Comments

7 Responses to “WordPress Permalink Structure”
  1. A suggestion when using the postname in the permalink structure: If the title of the post is very long, creating a long trailing URL, you can shorten it to whatever you want by editing the permalink that is between the title and post toolbar.

  2. Andy says:

    Yes, good tip. It is something I’ll be covering in a later tutorial on making posts, but its useful to be aware of this.

  3. Terry says:

    Help!

    When writing pages for Disclaimer, Privacy Policy and Terms I’ve run into an unusual problem.

    After writing my pages and ftp into my server as xxxdomainname.com/disclaimer, xxxdomainname.com/privacypoilcy, etc., I get 404 message when testing.

    The editable permalink structure reads as : http://xxxdomainname.com/disclaimer/ but, whenever I copy and paste the link from WP in my browser to test I get… http://xxxdomainname.com/disclaimerdisclaimer.

    I’ve tried a number of ways to solve the problem by renaming the file serverside to 1disclaimer and then editing the permalink and then going to the live page and clicking the link but still get 404 error message.

    Has anyone else had this problem?

    TerryH

  4. Andy says:

    Terry
    Via email, I suggested that the trailing “/” might be a clue. Did you look into that?

  5. Andii says:

    Hi Andy.

    I added the custom permalink but when I went to open the links I got an Internal Server Error: The server encountered an internal error or misconfiguration and was unable to complete your request.

    Here’s how the URL displays on one page: http://www.mrroomfinder.com/blog/chiang-mai/chiang-mai—making-the-move/

    I’ve had to restore the defaults. Any ideas please?

    Thanks in advance

    Andii

  6. Andy says:

    Sorry Andii, I dont know. Have you tried searching Google for the exact text of the error to see if others have had this problem?

  7. Andii says:

    Thanks Andy :)

    It’s just a general server error, but i will take a look just in case something pops up. I’ve got the feeling there’s something not quite right about by custom made blog :(

    Andii

Leave A Comment...