A comparison of web servers: Apache, Nginx, LiteSpeed and Microsoft IIS

A web server is a software that responds to clients requests over the world wide web. A client (e.g browser) sends a request for information and the web server responds to the client with the requested information or error message. There are many web servers available online and the choice of which one to use is dependent on many factors, which are beyond the scope of this article. Here, we will run a comparison of various characteristics of 4 popular web servers.

Apache

Apache is the most popular web server in the world. According to w3techs.com, 38.7% of websites around the world use Apache. This is more than any other web server. Below are some facts about Apache:

Created by: Robert McCool

Founded: 1995

Programming language: C, C++ and XML

Developers: Apache Software Foundation

Operating Systems: UNIX like, Windows

HTTP/2 and HTTP/3 Support: Yes

Open Source: Yes

Apache is preferred for shared hosting environments due to its flexibility via use of .htaccess to provide custom configuration settings for each user. Its the default web server for cPanel. It can also be used for load balancing, proxy server and WSGI applications via mod_fusion module.

Pros:

  • Reliable. It is battle tested. You can rely on its stability for your applications.
  • Because of its popularity, it has great documentation and support.
  • Changes via .htaccess do not require restarts.
  • Cross platform. Runs in almost all operating systems.

Cons:

  • Its slower than modern web servers.
  • RAM intensive under high load.
  • Requires disabling of unused modules to improve security.

Nginx

According to w3techs.com, Nginx is the second most popular web server with 32% of the market share. Nginx exists in two versions: OSS Nginx (nginx.org) which is free and Nginx Plus (nginx.com) which is commercial and adds a few more features compared to the open-source version. Below are some facts about Nginx:

Created by: Igor Sysoev

Founded: 2004

Programming language: C

Developers: Nginx Inc

Operating Systems: UNIX like, Windows

HTTP/2 and HTTP/3 Support: Yes

OpenSource: Nginx is FOSS, Nginx Plus is commercial

Nginx is a preferred alternative to Apache because of its ability to server many concurrent connections. It is also more popular as a load balancer, reverse/mail proxy

Pros:

  • Can manage 10k concurrent connections with low memory overhead.
  • Serves static files better than other web servers.

Cons:

  • Lacks flexibility as configuration is done via one configuration file unlike with Apache where configuration for specific sites can be overridden via .htacccess file.

LiteSpeed Webserver

According to w3techs.com, Litespeed web server has 6.5% of the web server market share. Litespeed has a commercial version and an open source version called OpenLiteSpeed (OLS). Some facts about Litespeed are as follows:

Created by: George Wang

Founded: 2003

Programming language: C, C++

Developers: LiteSpeed Technologies

Operating Systems: Linux Based

HTTP/2 and HTTP/3 Support: Yes

OpenSource: Litespeed Enterprise is commercial and OpenLiteSpeed is FOSS.

Litespeed is built for speed. It focuses on making websites load very fast, especially those created using CMS like WordPress, Magento and Joomla. It’s also drop in replacement of Apache that works where Apache works and understands the .htaccess directives of Apache. As such, its also usable in cPanel without many changes.

Pros:

  • Its a drop in replacement for Apache and can be used to bring in several improvements on speed to a website.
  • Its very fast.
  • Can be restarted without causing downtime
  • Supports unlimited concurrent connections
  • Less resource intensive even under high load
  • Integrates well with popular web hosting panels eg cPanel, Plesk, DirectAdmin and CyberPanel

Cons:

  • Its is not very popular hence support and documentation is still shallow.
  • Expensive licensing for Litespeed Enterprise

Microsoft IIS

Microsoft IIS servers 8.3% of websites according to w3techs.com. Microsoft IIS was developed as a replacement of European Microsoft Windows NT Academic Centre (EMWAC) as EMWAC could not handle the amount of traffic received on microsoft.com

Created by: Microsoft

Founded: 1995

Programming language: C++

Developers: Microsoft Corporation

Operating Systems: Windows NT

HTTP/2 and HTTP/3 Support: Yes

OpenSource: No

Can be used to run anything on a Windows environment. Its the default OS for windows hosting environments.

Pros:

  • Reliable as it can run any web application.
  • Generally more secure than Apache.
  • Comes free on Windows operating system
  • Extensive documentation and support

Cons:

  • Bundled with Windows and not usable in UNIX environments.
  • Non-opensource.
  • Its runs on Windows OS only.

Leave a Reply

Your email address will not be published. Required fields are marked *