Testing a move from WordPress.com to self hosted WordPress blog

Yesterday I was talking to m wife's cousin, Mihir, about blogging. He mentioned that he had started a blog about SQL Server (he's a DBA). His blog is hosted on WordPress.com but because WordPress.com does not allow javascript and ads he wanted to move to Blogger. However, Blogger provides no tools to move a blog to another host.

He was also concerned that readers would not be able to find the new home of his blog. I suggested that he purchase a domain name. Besides the benefits of branding his blog, he would also be able to move his blog at any time without losing readership.

That got me thinking and before I gave any advice on the matter I decided to see for myself how easy it would be to move my blog from WordPress.com to a self-hosted WordPress.org blog.

XAMPP logo

I chose to create a hosting environment on my MacBook. WordPress requires a system with PHP and MySQL. Specifically PHP version 4.2 or greater and MySQL version 4.0 or greater. Any web server will do. I know that OS X includes all of those but I decided I wanted something that I could easily remove. I downloaded and installed the XAMP package provided by Apache Friends, a non-profit project to promote the Apache webserver. The goal of the project is to provide an easy to install and configure web environment around the Apache web server, the MySQL RDBMS, PHP and Perl. From the Apache Friends web site:

At the moment there are four XAMPP versions:

  • a version for Linux systems (tested for Ubuntu, SuSE, RedHat, Mandrake and Debian),
  • a version for Windows 98, NT, 2000, 2003, XP and Vista,
  • a beta version for Solaris SPARC (developed and tested under Solaris 8),
  • and a beta version for Mac OS X.

The OS X version installs like a regular OS X application. To start up the XAMP services I launched the XAMP Control Panel and started the Apache and MySQL Services.

XAMPP Control Panel

Before installing WordPress I created a new database user (wordpress) and table to hold the WordPress blog data and gave it full privileges.

macbook:~ root# /Applications/xampp/xamppfiles/bin/mysql -u root mysql> create database wordpress;
mysql> create user 'wordpress'@'localhost' identified by 'password';
mysql> grant all on wordpress.\* to wordpress;

With the database set, I downloaded the WordPress tarball from WordPress.org and installed under the /Applications/xampp/htdocs/ directory. I chose the 5-minute install. For that, I edited the sample configuration file to add the database name and database username and password and ran the installation PHP script from a web browser. I also downloaded and installed the OpenID WordPress Plugin ( why not? ). What is OpenID?

Geekery:

OpenID is an open, decentralized, free framework for user-centric digital identity.

Huh?

OpenID eliminates the need for multiple usernames across different websites, simplifying your online experience.

Oh, ok!!

I like OpenID. I love going to a blog and with just a few keystrokes posting a comment with a link back to my site ( as well a cool avatar from Gravatar ).

Export blog from WordPress.com

Once the base installation was complete I exported my current blog from the WordPress.com web site. This is provided as a an XML file. I found an explanation of this on the WordPress.com web site.

This format, which we call WordPress eXtended RSS or WXR, will contain your posts, comments, custom fields, and categories.

I saved the file and then proceeded to import my blog back into my XAMP setup.

Well... I attempted to anyway.

Import blog failed

I checked permissions on the database and the file system and they are fine. I am not sure what to make of this. What do I do now?

Author: Khürt Williams

A human who works in information security and enjoys photography, Formula 1 and craft ale. #nobridge

9 thoughts on “Testing a move from WordPress.com to self hosted WordPress blog”

  1. I have visited this site on many an occasion now but this post is the 1st one that I have ever commented on.

    Congratulations on such a fine article and site I have found it very helpful and informative - I only wish that there were more out there like this one.

    I never leave empty handed, sometimes I may even be a little disappointed that I may not agree with a post or reply that has been made. But hey! that is life and if every one agreed on the same thing what a boring old world we would live in.

    Keep up the good work and cheers.

    1. @kOoLiNuS, I moved my blog to a self hosted WordPress. I am using BlueHost.com. When I make the time, I'll add a post about the move.

  2. Hi Khurt!
    It seems I cannot find the article I remembered about errors in XML exporting ... also a real quick search on the support forum haven't told me anything useful .... I'll have to ask to a couple of friends who are more in these kind of things ...

  3. if you like WordPress you or your wife's cousing can have a look to Blogsome which enables you to modify templates for free (and for sure handling CSS in a more advanced way than I'm capable of) and make use of javascripts (IIRC) even if all the service it's based on an older release of WordPress MU than the one you use here everyday ...

    {have a look to my friend's gustomela's blog to have a general idea of this CSS customization}

    on the XML importing side I remember that there's something to help and prevent the error, but today has been a long day so you'll have to wait tomorrow 😀

Comments are closed.