Install Nginx + PHP + MySQL on Mac Os in 2020

This tutorial shows how to install Nginx + PHP + MySQL on Mac OS Catalina.

It’s very straightforward process and doesn’t takes you more than 10 to 15 minutes.

Install PHP

First of all, ensure that brew brew is up-to-date and then install latest php 7.4 version.

To locate your ini files type the following command:

You should get output like that:

Install Xdebug

Very important step for any developer is to install debuger module.

From brew version, modules for php are installing with pecl only.

Type following command to install xdebug:

Then create and configure an additional .ini file for xdebug:

Reload php-fpm:

Verify you have completed successfully previous steps:

You should see the following:

Install Nginx


Install MySQL