Skip to content

zsh: command not found: php

I have been using php with mamp on mac for a year even with old versions of MacOS, since I installed MacOS Monterrey if I type php on the terminal I get a message:zsh: command not found: php

Using older versions of MacOS I have never had this problem.

How can I solve the problem?



I had the same issue after updating to Monterry. After some googling, I find out MacOS doesn’t include PHP. You need Homebrew to install PHP again.

brew install php

User contributions licensed under: CC BY-SA
7 People found this is helpful