Skip to main content

Install WordPress on Debian – Most popular CMS for blogs

WordPress is clearly the most popular blog platform / Content Management System.

Indeed it has all to please. Easy installation, well supported, big community, a lot of plugins, free, multilingual, etc….

Of course, some others CMS are very popular for blogs too like Dotclear but WordPress might be the one that does the most communication around its product.


So let’s see how to install this CMS. (Others CMS should follow the same principle)



Obviously, you need to have a proper HTTP server, PHP, database combo ready. In my case I’m using a LAMP configuration, Linux Apache, MySQL, PHP. If you haven’t install that, just check my previous tutorial on how to install a LAMP combo to host your own website.

Once done, most probably you will like to have a dedicated folder/database for your wordpress website.

The second command will change the owner of the folder (Previously root) by the apache user www-data.

Then download the latest WordPress archive inside your previously created folder:

Now, you will need to untar the archive in the folder. However the archive latest.tar.gz includes the subdirectory that includes all the files.

If you just untar with the regular:

You gonna have a folder wordpress in your /var/www/myblog

But we want to have all the needed files in /var/www/myblog directly, not in an additional subdirectory.

So you will have to move all the files from myblog/wordpress to myblog/ and remove the folder wordpress afterward.

But actually, you could directly untar all the content of wordpress folder directly in your current folder myblog with 1 command:



Now you will need to fulfill the wordpress conf file with your database information in order to launch the web-based installation interface of WordPress

Still in your /var/www/myblog folder run:

to use & modify the wp-config sample file, and modify those lines:

If you haven’t created a database yet for your website, I strongly recommend you to use PHPMyAdmin to easily do it. You can follow my previously created tutorial on how to install PHPMyAdmin and set up a database and user.

Once done, just save your wp-config file and point your web-browser to your server IP such as or point to your domain name/subdomain if you have configured a Virtualhost (Vhost) such as http://blog.mywebsite.tld for example.

If you haven’t done that, you can refer to the point 4 of my LAMP tutorial, dedicated on Virtualhost configuration.

And finally, just follow the quick web-based setup.

You should now have your blog ready !