How to Install XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

if you want a development site that can be used for testing or other purposes this is a best way to install WordPress locally with XAMPP. With XAMPP you can run a website from your very own computer with just a few clicks once you get it set up with Wordpress.

Butt its little tricky actually to install XAMPP and WordPress, So here's helping hand if you might need.

We’ve already discussed about benefits of a local WordPress testing site, so I won’t include that point. Instead that, I assume you’re just need the guide.


XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

Here’s exactly how to install WordPress locally with XAMPP. At the end of this, you’ll have your very own local WordPress testing environment running on Windows.


Step 1: Download and install XAMPP on your computer

To install WordPress locally, in first step you need to download and install the XAMPP software. You can download the installer for Windows and also for MAC and Linux file from Apache Friends.

xampp website - your tool to install WordPress locally

Once finishes the download, run the downloaded file to launch the XAMPP installer. Keep in mind, If you’re using any antivirus Software, you might get a warning like this:

xampp website - your tool to install WordPress locally

Now, Simply Click on Yes to continue installation. You might also get a prompt about User Account Control (UAC) Depending on your Windows configuration. Just click continue as well. After this you'll get the standard installer screen:

xampp website - your tool to install WordPress locally

Just select Next to continue. 

Now you'r at next screen where you need to choose components to install. To install XAMPP and WordPress locally, you don't need to install all of the components. Only required components, all you need are:

  • MySQL
  • PHPMyAdmin

XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

Now Uncheck all of rest and again click Next. That's all  needed to install WordPress with Xampp locally. 

You can now also select the folder location where you want to install XAMPP in. I always choose default to go:

How to Install XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

Now again, you will be at next screen, where you’ll get a prompt asking to install Bitnami for XAMPP. For current situation you don't need to install this, so just uncheck the box and go on:

How to Install XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

Once you click Next, you’re ready to run the install:

How to Install XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

The install process might take a few minutes:

XAMPP install process

Once it finishes, you can launch the control panel to start working with XAMPP:

go to control panel

Step 2: Start the modules and test your server

To install WordPress properly with XAMPP,  you’ll need to run two modules:

  • Apache
  • MySQL

You can start both modules from the XAMPP control panel:

launch the server

Once Activate these, you should see their status turn to green:

database install

And now you should be able to test that your local server is working by going to http://localhost/ in your web browser of choice:

everything on localhost

If all went well, you now have a functioning XAMPP server on your Windows PC! But now it’s time to install XAMPP and WordPress. So here’s how to get a WordPress site up and running on XAMPP.

Step 3: Add the WordPress files

If you’ve ever manually installed WordPress, the rest of the process should feel pretty familiar. First, you need to go to wordpress.org and download the latest version of WordPress.

Then, in Windows, navigate to the folder where you installed XAMPP. For me, that’s C://xampp. It should be something similar for you. Then, in that folder, find the htdocs subfolder:

add the files to the folder

It might take a few minutes(Great things take time):

After Completed installation go to C -> xampp -> htdocs folder. Here you need to create a new folder for your test site. You'll use this folder name for sub name to access your site. For example, if you make the folder testsite, you’ll access your site by going to http://localhost/testsite.

Once you create the folder, Download and extract the folder of WordPress .zip file:

XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

Step 4: Create a database for WordPress

Now, Here you need to create a database for your WordPress site to install. We are using MySQL Database here... To do that, Click on Admin button launch PHPMyAdmin from your XAMPP control panel and make sure Actions button of both Apache and MySQL is Clicked to Start:

XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

Then click on Databases at the top:

XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

And enter a name for your database, it may be your site name and other too and click Create. And remember the name you created the site with because you’ll need it for the next step:

XAMPP and WordPress Locally || How to Install Wordpress in Localhost Server

Unlike installing WordPress on a live web server, when you install XAMPP and WordPress, you don’t need to worry about creating a database user.

Step 5: Install WordPress locally via the on-screen installer

When you visit your test site, you should see the normal WordPress installer. Remember, your test site is just http://localhost/FOLDERNAME:

install WordPress on XAMPP

The only step where this process will differ from a normal install is the database details. When you get to the database details, enter them like this:

  • Database Name = Name of the database you created in PHPMyAdmin
  • Username = “root”
  • Password = leave blank

database settings when you install WordPress locally

Then finish the rest of the WordPress install process like normal.

Once you complete the process, you should see your brand new WordPress install running perfectly on your local host:

new WordPress site installed on XAMPP



Kaleem Khan

I'm Kaleem Khan Citizen of Pakistan. Student Of Bachelor of Computer Science at the Virtual University Of Pakistn.

Post a Comment

Please Don't Advertise or Spam Links and Messages Here.

Previous Post Next Post

Recent Posts

Recent Posts