Did you know that is possible to create a local development environment for WordPress so you don’t have to work on a live site?
For many years I developed on a live version of WordPress because I didn’t know it was possible to do it another way. So discovering that there was a tool that would make it super easy to work with WordPress locally was a complete game changer.
There are many benefits of using a local development environment. It’s safer because it means you aren’t messing around with the code of a live site, so if you mess up it’s not the end of the world. It’s also much quicker as you don’t have to upload changes via FTP, and there’s less issues with caching.
I also love the fact that you don’t need internet access to work on a local version of your website, which is great if you need some distraction free coding time (just turn off your WiFi and get cracking!), or if you have terrible internet like me (hurry up and install fibre, Openreach!).
In this post I’ll show you how to easily set up a local development environment for WordPress using a tool called Local by Flywheel.
Get access to my freebies library!
My exclusive freebies library contains cheatsheets, checklists and other resources to help you to create and run your dream website.
To access my freebies library and join my community just fill in the form below. Find out more information about my community right here.
1 | Download and install Local by Flywheel
To set up our local development environment we are going to be using a tool called Local by Flywheel. It’s complete free to download and very easy to use.
So, start by heading over to the Local by Flywheel website. The homepage looks a little something like this:
On this homepage, click Free Download.
This will open a box where you should select which platform you are using (Windows or Mac) and enter your details (you only really need to enter your email address and the number of websites you plan on using).
When you are ready, click Get it now! to start the download.
It may take some time for it to download, especially if you have terrible internet, like me!
Once Local by Flywheel has finished downloading, click on the file to begin the installation. You may be prompted allow changes to your computer throughout this process.
Eventually you will see a screen that looks like this. All you need to do here is click Let’s Go! and wait for the installation to run. It may take some time, so grab yourself a coffee or something!
2 | Set up a local WordPress website
After Local by Flywheel has finished installing you can set up your first local WordPress website.
You will see a screen that looks like this:
Click Create A New Site to set up your first local site.
You will be asked to give your website a name. This can be what ever you like, but you should ensure that it’s relevant.
When you’re done, click Continue in the bottom right hand corner.
Next, you will be asked to choose your environment (i.e. version of PHP, version of MySQL, etc.). I’m going to choose Preferred as I’m happy with the settings as they are, but you can choose Custom and choose your own.
Either way, when you are done click Continue.
Finally, you will need to choose a username, password and email address for your WordPress website. Again, these can be anything you like but you should make a note of them because you will need them to log into WordPress later.
When you’re ready, click Add Site. It may take a few seconds for your website to be added.
Eventually you will see a screen that looks like the one below. On the left hand side you have a list of your local sites, and if you click on them you will able to see more details about them.
3 | View your website and admin area
To view the local website you have just set up, click on View Site.
This is what it looks like with the Twenty Seventeen theme activated by default.
And if you look at the address bar you will see the URL for this local website. If you were to try and view this on another computer, it wouldn’t work.
If you would like to view the WordPress admin area for your site, click on Admin.
Existing WordPress user will already be very familiar with this login screen! To log into your admin area you need to use the email address and password you used when you set up this local site. I’ve found that you need to use your email address rather than your username.
And this is what the URL looks like:
4 | Access your files
Obviously if you’re setting up a development environment for WordPress then you are going to want to be access your files!
To access the files of your WordPress website, right click on the name of your local site and click Show Folder (or Reveal in Finder if you are a Mac user).
This will open the file explorer and in here you will see a file named after the local site you just up.
From here, double click on the name of your site, then app then public, and finally you will see your WordPress files.
Now all that’s left for you to do is to start using your local development environment! Happy experimenting!
Development not your thing?
If development isn’t your thing and you’d rather pass the work on to someone else then I can help.
Get in touch and find out how I can help you today.
Looking for more helpful advice?
Sign up to receive my free monthly newsletter!
On the last Friday of each month, I send out my monthly newsletter jam-packed with tips, tricks and resources to help you create and maintain the WordPress website of your dreams. And it’s completely free!
Simply enter your name and email below to sign up…