PHP is not recognized as an internal or external command in command prompt

Add C:\xampp\php to your PATH environment variable.(My Computer->properties -> Advanced system setting-> Environment Variables->path (click on edit))

Then close your command prompt and restart again.

Note: It’s very important to close your command prompt and restart again otherwise changes will not be reflected.

Leave a Comment