How To Install WordPress on Localhost XAMPP
In this tutorial, we are going to learn how to effectively install WordPress on your localhost server XAMPP. If you haven’t already installed XAMPP on your computer, go to the WordPress official site, download the software for free, and install on your machine.
What is XAMPP?
According to the official XAMPP site “XAMPP is the most popular PHP development environment.”
Furthermore, it is absolutely free and easy to install the software. This open source package is easy to setup and very powerful to use.
Ok, let’s begin how to install WordPress on your local machine using XAMPP.
How To Install WordPress on Localhost XAMPP
Before we begin, let us first know what we need to do. This will make you easier to remember in the future when you try to install WordPress by yourself without looking tutorials.
Important Things to Know before you install WordPress
- have XAMPP/WAMP Server install on your computer.
- have the latest version of WordPress.
- Create Database from PHPMyadmin.
- Know the username/password and the host of your MySQL server.
Step 1: Download And Install XAMPP Server
In order to run WordPress, you need both Apache and Mysql server and thankfully, XAMPP has these features. Go to https://www.apachefriends.org/index.html site and download the latest version of XAMPP. It’s really easy to install the software. Just keep on clicking Next & Next if you’re not sure of configuring the basic installation settings.
Note: It is recommended to install Xampp on another drive rather than the one your OS is running. For example, install the XAMPP on the drive D, if your Operating System is running on drive C.
Step 2: Download and Install The Latest Version of WordPress Software
This is the second step. Go to the WordPress official site and Download the latest WordPress version from there. Now locate your downloaded file ( comes in zip format) and go to the folder where you’ve installed your XAMPP Server. Inside D: -> Xampp -> htdocs folder, copy your zip format of WordPress file and extract it.
All you need to do is rename the WordPress Folder. For now, let’s name it as mysite. Do not delete your WordPress.zip file, you can always use it later for future projects. Also, do not name your project as wordpress. Always rename it once you extract the compressed version of WordPress.
Step 3: Create a New Database from PHPMyAdmin
One thing you need to know about WordPress is it’s all about database and database. Your pages, posts, widget contents, image sources all are stored in the database with different tables. So without a database, not only WordPress, installing other CMSs are not possible.
To create a new database, go to http://localhost/phpmyadmin from your browser. Locate Databases tab on the top and click on it. You now see the Create Database section on the Databases page. Write your preferred database name for your site and hit create button. For now, let’s name it mydb.
Step 4: Install WordPress
Now it’s time to install WordPress on our machine. Follow the below steps precisely.
- From your browser, enter the URL of your site/project i.e. http://localhost/mysite. This will automatically redirect you to a WordPress configuration page. Select English and click Continue button.
- Now before installing WordPress, you need to enter some information on the database. You will need to know the following items before proceeding.
- Database name (we’ve created database name mydb)
- Database username (default root)
- Database password (leave it blank)
- Database host (localhost)
- Table prefix (if you want to run more than one WordPress in a single database).
- On the database setup configuration page, enter your database information as the screenshot below:
Hit the Submit button if all the information is correct.
- We’re almost done now. If all the database information you provide is true, you’ll see the information on the new page saying, “All right, sparky! You’ve made it through this part of the installation. WordPress can now communicate with your database. If you are ready, time now to…“Click Run the Install button.
- We’ve finally installed our WordPress in Xampp. Still, we’ve not fully setup our site yet. You need to enter your website’s information like Site’s Title, Admin’s Username and Password, your Email Address. See the screenshot below:
Here our username is myusername and password is MyPassWord. This is the information from where you access your login page (i.e. /wp-admin) of your WordPress site. Always use username and password which you can remember easily but not easy to guess by others. Hit the Install WordPress Button.
Voila !! We’ve now successfully installed WordPress and created a new project titled mysite. You need to access your login panel of your WordPress site. It can be done by entering URL on your web browser as http://localhost/mysite/wp-admin or http://localhost/mysite/login.php. Either way, it will redirect you to the same login page. Enter your username and password we previously set up and you’ll be inside the Dashboard.
See you in our next tutorial !!