PHP can be install on your localhost as per your local machine operating system.
- Windows - XAMPP Server
- Linux - LAMP Server
- Mac - MAMP Server
So, download PHP server as per your local machine operating system.
XAMPP is the most popular PHP development environment
XAMPP is a completely free, easy to install Apache distribution containing MariaDB, PHP, and Perl. The XAMPP open source package has been set up to be incredibly easy to install and to use.
To Download Latest version of XAMPP visit official website apachefriends.org