How to Install WordPress Locally on Your Own Computer (A Step by Step Guide)

How to Install WordPress Locally on Your Own Computer (A Step by Step Guide)

Last Updated on May 24, 2022

If you run a WordPress website, then there’s a chance you’ve experienced occasions when your website went down – because of a plugin or theme update, or you got hacked, or maybe you just adjusted something in your settings. Installing WordPress locally is a great way to future proof your WordPress website and prevent it from going down.

This guide will teach you how to run WordPress locally. Your local website can be your platform where you can set up different types of environments that will allow you to test whether your site works well or not – without the risk of your live site breaking down.

There are various ways you could do this. You could have a staging site for you to run different tests, or you could install WordPress locally into your computer. Each way has its own merits of course, but for this guide, let’s dive deep into why installing WordPress locally on your own computer is a good option.

Why You Should Install WordPress Locally

  1. It’s a safe way to test WordPress core, third party plugins, and theme updates to test for breaking changes. You won’t have to manually fix the issue on your live website or restore it from an earlier backup. You can easily find the issue on your local host and push it to your live website.
  2. Since your site is hosted on your computer, you won’t be relying on an internet connection to access your environment. This allows you to work on your website and/or find and fix issues faster.
  3. It’s free! You won’t need a web host or possibly pay an additional fee for a staging site. 

Comparing Local WordPress Development Tools

There are a lot of tools and PHP servers that you can choose from. It’s easy to get a bit confused on which one may be the tool for you. To make it easier for you, here is a comparison of three commonly used development tools:

1. XAMPP

XAMPP is a free open source platform and supports major operating systems (i.e. Windows, MacOS, Linux). XAMPP stands for X-platform Apache MariaDB, PHP and Perl. It stacks all the programming languages and databases that you need to set up your WordPress environment. 

Key features

  • Free and open source
  • VM-based local WordPress experience for MacOS users
  • Allows for setting up a software stack including Apache, MariaDB, Perl, and PHP
  • Easy-to-use dashboard where you can manage your WordPress website

If you’re interested in installing WordPress locally using XAMPP, check out this article from WP Beginner.

2. MAMP

MAMP stands for My Apache, MySQL, and PHP. It is a free platform with a pro version for those who’d like additional functionality. MAMP PRO for Mac is actually the only version that has a built-in WordPress publisher, importer, and server migration.

Key features

  • Free
  • Allows for setting up a software stack including Apache, MySQL, and PHP
  • Easy installation with option to set up custom environment

Learn about how to install WordPress locally using MAMP in this article by Themeisle.

3. Local by Flywheel

Local by Flywheel is a free platform that’s built exclusively for WordPress development. Though the free version is already jam packed with everything you need for WordPress development, it also offers additional functionality for a fee.

Key features

  • Free
  • One-click WordPress installation
  • Easy-to-use and intuitive interface
  • Easy installation with option to set up custom environment
  • Includes programming language and databases needed for WordPress

How to Install WordPress Locally using Local by Flywheel

At Stackable, we actually use Local by Flywheel to develop our plugin. We also use this for sandbox websites where our designers and writers create tutorials and test new features and development.

We’d like to show you how you can install WordPress locally using Local by Flywheel. The installation process is generally the same for both Windows and MacOS, so it won’t be too difficult to follow along. 

Let’s get to it!

Downloading Local by Flywheel

  1. Go to https://localwp.com/ and click Download on the menu bar. Fill up the form then your download should begin afterwards.
Accessing Local by Flywheel
Visit Local by Flywheel and download their app
  1. Once your download finishes, open the .exe file for Windows or .dmg file for MacOS. Follow the instructions for the complete installation of the program.
Installing Local by Flywheel
Installing Local by Flywheel

Creating a new site

  1. Once you open the program, you have the option to create a new site. Click the Create New Site button.
Creating a site on Local by Flywheel
Creating a site on Local by Flywheel
  1. Give your new site a name. Click Continue.
Creating a site on Local by Flywheel
Creating a site on Local by Flywheel
  1. Select the environment you prefer, just pick Preferred to quickly get started. For advanced users, you can also customize your PHP version, the type of Web Server to use – nginx or Apache, and your MySQL version. You can adjust these settings later as well.
Creating a site on Local by Flywheel
Creating a site on Local by Flywheel
Creating a site on Local by Flywheel
Custom settings when creating a site on Local by Flywheel
  1. Enter a username, password and email address for your login credentials. Click on Add Site.
Creating a site on Local by Flywheel
Creating a site on Local by Flywheel
  1. Once the initialization is complete, you will have created a new site locally on your computer! To visit your local website in your browser, click on the Open Site button, or you can visit your site by using the name with a .local in the end. For example, ours was https://sandbox.local
Install WordPress Locally on Your Own Computer
A list of all your WordPress sites on your own Computer

What Can you do with your Local WordPress Website?

Now with your WordPress website available locally, what can you do with it?

Well if you have an existing WordPress website, you can import an existing website into Local, and make all your developments locally. This can be done by downloading a zip file of your WordPress site manually from your website host. To make things easier, you can use a third party plugin like Backup Buddy Pro. You can also do this in the other direction, to export your website into your live website.

You can also share your local WordPress website online by turning on Local’s very useful Live Link feature. Turning it on would create a temporary url that looks like this: abcdef1.ngrok.io that you can share with others. This is very helpful if you’re building a website for a client and you want to share your progress.

If you’re a FlyWheel customer, you can use the new site you created as a staging site where you can build your WordPress website from scratch. You can push this new site to a live website by connecting a host and adding a live link. 

Quick recap on installing WordPress locally on your own computer

By installing WordPress locally on your own computer, you are given the ability to make various changes to your site like testing themes and plugin compatibility without the risk of breaking your live website. 

There are various methods on how you can set up your local WordPress environment, like XAMPP, MAMP, and Local by Flywheel. In this article, we taught you how you can do it using Local by Flywheel.

Let us know if you tried installing WordPress locally in the comments below. If you have any suggestions or questions, don’t hesitate to reach out to us!

Want to learn more
about Stackable?

Your very own Learning Hub for all things WordPress and Stackable. Find the right resources to help get you started as you begin building your online presence with Stackable.

0 thoughts on “How to Install WordPress Locally on Your Own Computer (A Step by Step Guide)

  1. Hello,
    Thanks for this guide.
    Unfortunately for me (and others colleagues around me) Local by Flywheel became more and more slow then ceased to function one day on my Mac. De-install/Re-install does no good, it won’t open anymore.

    One other solution I like is Ampps. A little tricky to install but then it create WP sites very quick without having to create first a database. It still works for me but it seems a bit old now. I don’t know if it is maintained.
    Cheers

    1. Hey Marc!

      Sorry to hear that’s your experience with Local by Flywheel. It runs smoothly on our end so its really unfortunate it does not work anymore for you 😔

      As for Ampps, thanks for bringing this up to our radar! But you’re right it seems if its not maintained since there hasn’t been an update recently from their end. Glad though it works very quick for you!

  2. I like the sound of FlyWheel to work on my websites locally. It would be so nice to work on my sites and then upload them. I have the new ones in a subfolder so the general public doesn’t see them. However they can be found.

    I did have problems with an older WordPress update so this would be wonderful.

    Thank you
    Victoria

  3. Hi,

    I have two questions.
    First, Is it necessary to have the same configuration, such as, the same web server (cannot have Apache on one site and the other site nginx); the same PHP version; the same database and the same version (not one MariaDB and the other MySQL and same version) between the local and the live host?

    Second, can the local be uploaded using ftp or FileZilla, and which files/folders to upload?
    I do have a live website, but it is still under development. I don’t mind replacing it with the local because what I do now is I just recreate all the setting I’ve done on the local site.

    Thank you.

    1. Hey Adolf!

      1) Ideally yes for some aspects like the web server type and MySQL versions. Doesn’t have to be the same for most cases, while running the site it would more or less behave the same for a typical website.

      2) For files, you’d have to copy over the entire wp-contents folder. However, you’d also have to move your database entries to the live website and rename some entries to point to the new domain. Instead of doing things manually, it’s better to use a backup plugin or a backup solution provided by your web host to make sure your transfer is done correctly.

      Hope these help! ☺️

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.