WordPressers – make your URLs readable!

I’ve noticed that quite a few folk who have installed their own version of WordPress (as opposed to those that use WordPress.com) haven’t got round to making the URLs (the bit that appears in the address bar of a browser) of their posts ‘human readable’.

In other words, they look like http://www.myblog.com/?p=1027 rather than http://www.myblog.com/postsubject.

Why would you want to make your links appear in this way?

  1. It helps in search engine optimisation – if the link says something about the content, Google etc like it
  2. It makes it easier for people to know what they are getting before they follow a link to your site
  3. It probably helps accesibility-wise

That’s enough reasons. Anyway, if you are a WordPress user, changing the way your post URLs – or ‘permalinks’ as they are known – is pretty easy. All the options are in the control panel, just click Settings then Permalinks and choose an option from:

  • Default: http://davepress.net/?p=123
  • Day and name: http://davepress.net/2008/06/17/sample-post/
  • Month and name: http://davepress.net/2008/06/sample-post/
  • Numeric: http://davepress.net/archives/123

I use the second option, day and name. Once you have made your choice, just hit Save. That should be it.

The only complication because of the way a file is setup on your server, called .htaccess. For WordPress to make the changes to your post URLs, it needs access to write to this file. If it, can’t, it will provide you with the code you need to paste into your .htaccess file to get it all to work. Don’t worry, this is pretty simple and you should be able to do it within your web host’s control panel.

Another thing not to worry about are all those links out there on the web linking to your old, number based, post URLs – these will still work!

5 thoughts on “WordPressers – make your URLs readable!”

  1. Nice post Dave. When I remember it is often worth using the facility to customise the url – which can condense it’s length to just the key words that help search find your stuff.

  2. Thanks Nick. Changing the URL on a post by post basis is easily done in the latest versions of WP by editing the URL that pops up under your post title while you are typing.

    For older installs, it’s buried in the Post Slug option on the right hand side.

  3. Letting WordPress write your main htaccess file is a minor security risk. Don’t do it: edit the file yourself as instructed by WordPress when you edit the options.

    I can’t remember whether this is fixed now: if you edit the permalinks, does WordPress redirect the old locations to the new ones? If not, you run the risk of search engines seeing “duplicate content” which is a bad thing, as explained on http://www.grahamjones.co.uk/2008/06/unique-content-is-vital-on-your-web.htm (although it doesn’t seem quite as bad if it’s only duplicated on one site, in my experience).

  4. Thanks for the security tip. I believe that WordPress does redirect the URLs automatically, but it also republishes your RSS feed, so all readers will get hit with your last 10 posts again 😉

Comments are closed.