The How and Why of Installing WordPress on Your Own Computer

Computer monitor displaying the "Get WordPress" screen

Updated:

|

Published:

If you’re considering WordPress or if you already have a WordPress website, a local installation provides a perfect testing and learning environment. In this article we’ll look at what a local WordPress installation is and why you may need one. We’ll also explain how to install WordPress on your own computer.

What is a Local WordPress Installation?

WordPress is free to download and use but you still need a domain and hosting that you’ll have to pay for. Your website is stored on your hosting providers’ server and all the files that WordPress needs to work are saved there. This includes all your content like the text, images and video that make your website.

A local installation of WordPress means setting your computer as a server called localhost and installing WordPress directly. This way all the content and working files are located on your own computer and you won’t need to pay for a domain or hosting yet. A locally hosted website is only accessible from the computer it is hosted on and is meant for development and testing before making a website live.

Why Install WordPress Locally?

You may not want to commit to a hosting account if you only want to take WordPress for a “test-drive”. You may also want to create and perfect your website before making it live. By installing WordPress directly, you’ll be able to test, learn and develop on your own computer without hosting or an internet connection.

If You Are New to WordPress

WordPress is often described as being easy to use, but there can be a fairly steep learning curve for beginners. If you are completely new to the world of websites, a local installation of WordPress will give you a platform to learn how to use WordPress and familiarise yourself with the terminology.  

For More Advanced Users

If you are already using WordPress, you can use a local installation to safely test and experiment with customising your site by adding and editing code. You can create a clone of your live website on your local computer for testing purposes so that there’s no risk to your live website.

If you’ve learnt a bit of HTML and CSS coding, you can also practice and hone your skills safely with a local WordPress setup. You may also want to get your feet wet with more complex coding languages like PHP and JavaScript.

Experienced WordPress Users

WordPress theme and plugin developers use local installations to develop and test their products before making them available to the public. A local WordPress installation is the perfect place to start if you also want to learn how to develop your own themes or plugins.

How to Install WordPress on Your Own Computer

We’re going to use XAMPP to set up a server and the basic requirements for a WordPress website.

Step 1 – Download and Install XAMPP

  • Visit the Apache Friends website and download the version of XAMPP for your operating system. (We downloaded the Windows version).
Apache Friends screenshot
  • Be patient as the file is quite large and may take a while to download.
  • Run the downloaded file to launch the XAMPP installer. If you’re running antivirus software, you may see a warning message. You can just click Yes here to continue. If you get a warning message on User Control, you can also just click OK.
  • You should now see the XAMPP installer screen. Click Next to continue.
The XAMPP installer screen
  • On the next screen you’ll be asked to select the components to install. The only components you really need are MySQL and PHPMyAdmin , but you can leave it as is and click Next to continue.
  • You now need to select the folder to install XAMPP in. You can leave this as the default and click Next to continue.
The XAMPP Installation Folder screen
  • On the next screen you’ll be asked if you want to Install Bitnami for XAMPP. You don’t need this to install XAMPP so un-check the box and click Next to run the installation.
The Bitnami for XAMPP screen
  • You can sit back now while XAMPP is installed.
  • When the installation is complete, click Finish to start the control panel.
XAMPP Installation Complete screen

Step 2 – Start and Test Your Local Server

  • Start the Apache and MYSQL modules in the XAMPP control panel.
The XAMPP Control Panel
  • When the modules have started, their status will turn green.
XAMPP modules started

You can test that your new local server is working by going to http://localhost in your browser.

The XAMPP welcome screen

You should now have a working server on your own computer. In the next steps,we’ll create a database and install WordPress.

Step 3 – Create a Database for WordPress

  • To Create a database you’ll need to open PHPMyAdmin from your XAMPP control panel.
  • Click on the Admin button next to MySQL.
Start PHPMyAdmin in XAMPP dashboard
  • Click on Databases at the top of the PHPMyAdmin screen.
Select Databases in PHPMyAdmin
  • Enter a name for your new database and make a note of the name because you’ll need it later on.
  • Click the Create button and you should see your new database listed on the left hand side of the screen.
  • You can close PHPMyAdmin now.

Step 4 – Create a Folder for Your Local WordPress Installation

  • Before you download WordPress, you need to make a folder for the new Installation.
  • In your file manger, navigate to the folder where XAMPP is installed. If you followed the steps above, it will be c://xampp.
Navigate to the XAMPP folder
  • Find and open the htdocs folder.
  • Inside htdocs, create a folder for your new local WordPress installation. This folder name will be used to access your site. In our example we called it mywebsite.
Create folder in htdocs for the local WordPress installation.

Step 5 – Download and Install WordPress on Your Computer

  • To download the latest version of WordPress you’ll need to go to wordpress.org.
  • Click one Get WordPress at the top of the screen.
  • Click on the download and install link.
Download the latest version WordPress
  • You can now click on the download button and wait while the zip file is downloaded on your computer.
  • Unzip the contents of the downloaded file into the folder you created in step 4.
  • Open the folder and find the file wp-config-sample.php.
  • Rename the file to wp-config.php.
  • Open wp-config.php in a text editor.
Edit wp-config.php file
  • Replace ‘database_name_here‘ with the name of the database you created in step 3.
  • Replace ‘username_here‘ with ‘root’.
  • Edit ‘password_here‘ so that it’s empty.
  • Save your changes.

When you visit your local website now, you should see the normal WordPress Installer. The address for your local site will be http://localhost/FOLDER/ (FOLDER will be the name of the folder you created in step 4).

Wordpress 5 Minute Install welcome screen
  • Complete the required fields and click the Install WordPress button.
  • When the installation is complete you’ll have a brand new WordPress site running on your own computer.
WordPress success screen

Need Help with WordPress?

Please free to contact us with any questions regarding WordPress. Visit our home and services pages for more about us and what we do.

Cimeron Collins

Cimeron Collins

Cimeron is an artist and designer who lives in Edenvale, South Africa. He has more than 30 years experience in the printing and publishing industries.

He is an avid WordPress enthusiast and passionate about learning and experimenting with new developments and technology in website design and development.

Please share this article if you found it useful

Leave a Reply

Your email address will not be published. Required fields are marked *

Top