As I was starting out in web development, I made a lot of rookie mistakes: not using version control, coding directly on production, etc. As I gained experience, I inevitably learned the better ways of doing things. To me, not using a local WordPress environment as a development tool falls into this category of missteps inexperienced developers or site owners often make.
Local WordPress development environments provide a great testing ground for plugins and themes. A local development environment is a great way to work on various client projects before pushing them to a staging web server.
I typically have three environments for every project: my local environment where development primarily takes place, the staging environment on the site’s host and then the production environment (live site).
Why Not Just Develop on the Staging or Dev Environment?
While there are more advantages to running a local installation of WordPress, my personal favorite is when developing locally is you aren’t reliant on an internet connection to work on your WordPress website. If ever my wifi was down prior to developing locally, that time was lost. If traveling and suffering through a slow internet connection or trying to work on a plane on those painful speeds, everything slowed. With developing on my local machine, I can pretty much continue developing as I otherwise would. Obviously, anything that requires wifi like interaction with third party APIs, pushing to servers or similar is impacted but it’s definitely not a total loss of time.
Simple Ways to Set Up a Local WordPress Environment
When you start reading about local WordPress development, it can be a bit intimidating, especially if you’re just getting started with WordPress. Reading about MAMP, XAMPP, Docker, etc. can be overwhelming and discourage users who just want to simply create a local WordPress environment. A lot of people avoid local WordPress development because they think it’s just way too complicated to get up & running. However, there are tools out there that drastically simplify setting these up and walk you step by step through the process. If you’re wanting to install WordPress locally & painlessly, I highly recommend one of these tools:
DesktopServer (referral link but genuine recommendation!): DesktopServer is a great tool that works on Mac or Windows. It has both a free and premium version. When creating a new WordPress site on your local machine, it walks you through the process and you’re up and running with a few simple clicks of a button. The premium version includes local SSL support, as well. One of my favorite things about DesktopServer is the ability to create blueprints, which are essentially custom starting points when generating a new environment. If there are a couple plugins you typically use or a starter theme you always begin with, you can easily create a blueprint with these.
Local by Flywheel: Local by Flywheel is another tool that easily spins up local WordPress environments with both a free and premium version. If you’re hosted on Flywheel, I’d especially recommend this tool as it integrates super well with their own hosting. Local by Flywheel offers a bit more control over configuration of the local environment like choosing a specific PHP version or MySQL version (to match production server specs, for example.) It also supports blueprints.
With either of the above tools, you’ll be well on your way to running WordPress locally in no time.