Dorokhov.codes

Choosing a web server

PHP can work either as a CLI scrip or a as module for a web server.

There are several web server options available for using PHP.

  • Apache HTTP Server: Apache is one of the most widely used web servers and supports PHP through the use of the mod_php module.
  • Nginx: Nginx is a high-performance web server known for its scalability and efficient handling of concurrent connections. It can be used with PHP via FastCGI or PHP-FPM (FastCGI Process Manager).
  • IIS: IIS is the web server provided by Microsoft for Windows-based servers. It can run PHP applications using the PHP module or PHP-FPM.
  • Lighttpd: Lighttpd is a lightweight web server designed for speed and efficiency. It can be used with PHP through FastCGI.