VPS Dedicated server

A few words about web servers. What is it and which server to choose?

A few words about web servers. What is it and which server to choose?

We frequently talk about servers and about what is better to choose for work purposes. We want to remind you that you can still order a lease of VPS/VDS, a dedicated server, or a storage server for your business or other purposes from King Servers. Today, we will discuss another important thing - web servers. Let's figure out what it is, how it works, and what option it's better to choose for your site.

What is a web server?

A web server is a server that receives a request from a user in the form of a URL, processes it, and sends the necessary data in the form of HTML pages, documents, media files, and media streams. This name implies both software and hardware. Like software, a web server consists of several components necessary to process user requests. Among them, the HTTP server is mandatory. Considering the web server as hardware, we can say that it is computer equipment on which documents are stored (the user sends a request to get them). The hardware must be connected to the network so that the client can retrieve the requested data from the server.

Web servers are often confused with application servers; besides, some use these names as synonyms. In fact, they can be called analogs, but not quite. Web and application servers have several differences. The web server is HTTP-only and is primarily designed to send static data. The application server supports both HTTP and other protocols, like RPC and others, and their key goal is to transfer dynamic, that is, constantly changing content. Initially, they have different tasks. Nowadays, web servers often support PHP, Python, and other scripting languages, so they interact not only with static but also with dynamic data. Among the components of most application servers, there are also web servers that are used as proxy servers.

But this subject should be discussed in a separate article. In this publication, it is important to explain how the web server works and by what algorithm the interaction between the server and the customer is carried out.

How does the web server work?

Let's consider the common example that all Internet users face every day.

A person wants to go online and visit a specific site. To do this, he/she opens a browser on a computer or mobile phone. When the program opens, the user enters the desired URL into the address line, navigates to the saved address in bookmarks, or clicks on a link on an already opened resource. It doesn't matter how, but the user goes to the site. In a few seconds, the requested page with text, pictures, video, and other content appears on the screen.

This is what the process looks like from the point of view of any layman. So, now, let's try to understand the basic internal processes.

The user opens the client application. Most often, this is a regular browser like Google Chrome or Mozilla Firefox. It can be installed on any device that supports this capability. It can be a PC, smartphone, tablet, or even a game console with the option of installing a web browser. The user transmits the request over the HTTP protocol, which arrives at the web server. Using a URL is a request itself. The web server processes it and sends the requested data to the user. It can be a regular HTML page, images, or other media files. The web server sends resources to the user using the same HTTP protocol.

If we describe the process briefly, we get the following algorithm:

  1. The user sends an HTTP request.
  2. The web server receives the request and processes it.
  3. The web server sends an HTTP response.
  4. The user receives the requested resources.

This is the basic way web servers work. Nowadays, sites are not limited to simple static pages, so resource transfer is a more complex process. For example, web servers provide the ability to securely receive and send data over the HTTPS protocol, support script languages ​for transmitting dynamic content, etc.

Thus, each user of the Internet, without knowing it, contacts web servers daily.

The first web server in history is CERN httpd, which was launched in 1991. Nowadays, there is a large number of servers, so it is not so easy to decide which one to choose. From the point of view of the client, there is absolutely no difference in what web server is used on a particular platform. But site owners try to choose the best option for their resources.

If we consider statistics on the Russian-language Internet,  in 2020 Nginx, Cloudflare and Apache hold the lead among web servers. Nginx accounts for more than half of the sites - 66.21%. Cloudflare ranks second - it is used in 8.51% of cases. Apache Web Server is used on 5.45% of platforms.

Global statistics, although not radically, differs from runet data. The top three most popular servers in 2020 include:

  1. Apache.
  2. Nginx.
  3. IIS.

Taking into account world statistics, we will consider these web servers as the most common.

Apache

Apache HTTP Server was introduced by its developers back in 1996. This is one of the first web servers in the market. After launching the software (free access), Apache has overtaken all competitors and is still leading these days. In the world, it is used on 40.89% of sites.

10 years ago, Apache was used as the main and only web server. Nowadays there is more data, and an increased number of connections, but this server is always enough. Apache is often used as the main web server. Besides, it is combined with other solutions. This web server is freely available and can be used for free.

Apache is cross-platform software. It supports all major operating systems, including Microsoft Windows, Mac OS, and UNIX-like operating systems. From an architectural point of view, Apache consists of a core that performs basic tasks, and a large number of additional modules. The core works always. Modules can be connected and disconnected, which allows you to control the functionality of the server.

Nginx

The creator of Nginx is the Russian developer Igor Sysoev, who released the product in 2004. This is the only Russian web server on this list. Nevertheless, it is popular in other countries - it accounts for 23.77% of all sites in the world. Nginx is used not only by owners of ordinary sites but also by market giants - Facebook, Pinterest, Netflix, Tumblr, Instagram, and many others. Like Apache, Nginx is an open-source product. But it can only be used on UNIX-like Microsoft Windows operating systems, which is why this web server is slightly inferior to the world leader.

During the development, some significant shortcomings of existing web servers were taken into account, including Apache. Thanks to this, Nginx perfectly copes with increasing load and easily withstands several thousand requests at a time.

As for flexibility, Nginx is inferior to other products. For example, modules need to be selected and compiled with the core, as they can not connect dynamically. But self-connecting modules can also be called a plus because users can choose only the necessary ones and avoid arbitrarily turning on the remaining modules.

IIS

IIS, or Internet Information Services, is a Microsoft product. Therefore, it can only be used in this operating system. Version 1.0 was released in 1995. Currently, IIS Web Server is used on 16.45% of all sites in the world.

Technically, this is a package of servers with the main component in the form of a web server. Unlike Apache and Nginx, IIS is not freely available. It comes together with an OS from the Windows NT line.

In terms of functionality and performance, IIS is at about the same level as the more popular free solutions. Developers pay great attention to security and improve it with the release of each new version - IIS surpasses Apache and Nginx in this matter. Due to the fact that IIS is commercial, users can count on Microsoft support, which is especially important for big businesses. Significant disadvantages include working on only one platform and the need to buy a Windows license. The second factor suggests that IIS is conditionally free since you do not need to buy a product, as it is already included.

If you're a site owner, you can't do without a web server. It is great that there are many products on the market and they can be combined. For example, many consider the combination of Apache + Nginx optimal. The main task is to choose the right option in terms of performance, security, and cost.

Guide: How to build an impressive freelance website
VPS

Guide: How to build an impressive freelance website

Freelancers often neglect the need for a personal professional website, and that’s a mistake. While one could be fine without it, a site will make lots of things

Core Web Vitals 101: the quick SEO guide for 2021
Business solutions

Core Web Vitals 101: the quick SEO guide for 2021

Every person who has to deal with search engine optimization knows that the key to success is to keep up with every whim of Google. We just got ourselves settled

Customer retention: how to improve it and raise your income
Dedicated server

Customer retention: how to improve it and raise your income

It’s not always about new customers. While reaching potential clients who didn’t buy your products or services yet is necessary, working with existing ones