How do I set up a local Drupal development environment?

The recommended approach in 2026 is to install DDEV, which handles Docker containers and the full web stack for you.

After installing DDEV, create a project folder, run ddev config to set up the environment, then use Composer to pull in Drupal. A few more commands get the database imported and the site running locally with a .ddev.site address.

Alternatively, Lando offers a similar workflow. For more hands on control, you can install PHP, a web server, and a database directly on your machine, though this route requires more setup time and ongoing maintenance. Whichever tool you choose, the goal is a local environment that mirrors production as closely as possible so surprises at deployment are minimised.

Facebook
Twitter
LinkedIn
Pinterest