How to Create a Local WordPress Website in Windows with Xampp

I believe that all WordPress users should have a local
installation of WordPress on their PC. The benefits are numerous – you
can test themes, plugins, and fiddle with a blog’s design without anyone
seeing. It’s lightning quick. There is no danger of being indexed by
Google. You can even take a whole website, download it to a local
WordPress installation, and play around with it to your heart’s content
before uploading the changes.
But local installations of WordPress aren’t just for developers. For
instance, I have an offline accountability blog that I use to keep track
of my life goals. I have another local WordPress installation where I
draft articles that I write for clients.Whilst setting up a local WordPress website may instinctively feel like it would be a complicated process, in reality, it is not. Any competent PC user can have a local WordPress installation up and running within a few short minutes.
1. Download and Install Xampp
In order to install and run WordPress locally, you need to create a local server environment. Fortunately, this is easily done with a free piece of software called Xampp. You can download Xampp from this location – click on the “Installer” option:

Proceed through the installation process – there is no need to adjust any of the default installation settings.
2. Set Up Xampp
Once the installation process has completed, load Xampp and Start the Apache and MySQL modules:


3. Create a Database
Every WordPress installation needs its own database, so before we install WordPress proper, we need to create one.From the same screen where you Started the Apache and MySQL modules, select the MySQL Admin button. This will open up phpMyAdmin in a browser tab. Select the “Databases” tab – here you will create your database:

4. Download, Configure and Install WordPress
Grab yourself a copy of the latest version of WordPress from the WordPress.org home page. Once downloaded, unzip the file. I would recommend that you give the resultant folder the same name as your database.Find the location where you installed Xampp (if you didn’t change the directory during installation, it will be “C:/xampp”), and open up the “htdocs” directory. Paste your WordPress folder into this directory. This is where your local website’s files will live.
Double click on your WordPress folder and open the “wp-config-sample.php” file with Notepad. There are a few variables you need to change in here:

Once you’re done, save the file and rename it as “wp-config.php” (i.e. remove “-sample” from the filename).
The only thing left to do now is install WordPress using the 5 minute installation process (which in reality will take about 30 seconds).
Open up a fresh browser tab and navigate to “http://localhost/yoursitename/”, where “yoursitename” is the name of your WordPress site’s directory. You will be presented with a familiar screen:


Enjoy!
Comments
Post a Comment