Setting up a webserver is relatively simple to do, however may become slightly challenging for those unfamiliar web servers. It may also be difficult if you are new to PhpStorm development environment. I assume you have PhpStorm downloaded, installed and registered. I also assume you have your project (or at least a simple index page) ready to go for testing.
Begin by downloading XAMPP or Wamp. Its up to you however more often than not i find more success with Wamp.
Ensure that you have Wamp and or XAMPP downloaded and installed. Note down the directory on your machine where you installed.
In PhpStorm dropdown file and select settings... Under Languages & Frameworks select PHP. If you do not yet have an interpreter you will see the following.
Select the option to add a new interpreter.
From the left menu + add a new item. Pick a generic name for your interpreter. I suggest including the version of PHP you are using as sometimes i want to switch between them when in different environments.
Under the PHP executable option link to the PHP path our where you installed Wamp or XAMPP
You now have everything set up and ready to go. You can now add this interpreter option to your Run/Debug configurations and you are all set to run your PHP application.