Moving Your WordPress Blog to a New Directory

In a previous article I mentioned that you should carefully think about your blog’s placement. For instance, do I want people typing http://www.BigBizBlog.com/blog/?

But it’s just not aesthetics – search engines get used to directory structure, and the very worst thing you can do is move files around on them (at least, if you want them to index your site for those billions of people hungering for your product).

So here’s my blog rule of thumb:

If you start a website and your domain name has the word ‘blog’ in it, you’re doing a blog, pure and simple!

This came to me again while reviewing my weekend’s work – oBoyBlog is actually located in a subdirectory. Despite being a site about a blog, the blog wasn’t front and center in the directory layout.

So I decided to fix it – here then are the tips for moving WordPress to another directory on the same domain:

  • Back up all the files from you old blog directory (in my case, ‘blog’).
  • Copy them to your new location (in my case the root directory).
  • Run the old setup and login, then change the location of the blog (‘General Options’, ‘WordPress address (URI):’ and ‘Blog address (URI):’).
  • Log out of the blog, and log in at the new location (eg from http://YOURBLOG.com/blog/wp-login.php to http://YOURBLOG.com/wp-login.php).
  • If you’re using PermaLinks, make sure your .htaccess file is updated with any necessary changes.
  • cleanup the old directory.

Make sure that whenever you make edits to your blog that your widgets and plugins such as social buttons, WP Cache, polling software, and others of your favorite plugins are saved.

By the way, that cleanup step is optional – in fact, you could place an index.html file in there so old visitors are told about the new location – if you want, add a met refresh tag so they automatically get sent over (I’ve done one for oboyblog.com):


<META HTTP-EQUIV="Refresh" CONTENT="5; URL=http://www.YOURSITE.com/">

One detail – because I already had an index.html file in the destination directory, I had a few moments wondering why my install didn’t take. If you have that problem, remember to remove it.

So the move was straightforward, and I’m up and running in the new location. But despite being relatively easy to do, remember if the site is devoted to a blog, put the blog in the main directory – and save the hassle.

3 thoughts on “Moving Your WordPress Blog to a New Directory

  1. Great tips on directory listing. I have a friend who encountered the problem you mentioned and up until now has a very hard time in fixing it. I told her about your post.

  2. Thanks so much for this information! I’m considering moving my WP installation, and making a WP site instead of just using WP for my blog, and this is exactly the info I needed. I just wish I’d realized how flexible WP is before setting up my site in the first place.