Learn how to setup and configure PhpStorm for debugging with MAMP and Xdebug.
I must have read 8 – 10 articles scattered about the internet when I first got PhpStorm setup to do debugging with Xdebug and MAMP. Each article seems to be missing one key piece of the puzzle. After a few days mucking with everything, I was able to get the stars to align. And it’s one of those things that, once you get it working, it just works and you don’t have to bother with it again.
Source: How To Setup PhpStorm, Xdebug, and MAMP for Debugging