How do web servers work

What is the web server?

A web server stores and delivers the content for a website - such as text, images, video, and application data - to clients that request it. The most common type of client is a web browser program, which requests data from your website when a user clicks on a link or downloads a document on a page displayed in the browser.

A web server communicates with a web browser using the Hypertext Transfer Protocol - HTTP or HTTPS. The content of most web pages is encoded in Hypertext Markup Language - HTML. The content can be static - text and images or dynamic - computed price or the list of items a customer has marked for purchase.

To deliver dynamic content, most web servers support server‑side scripting languages to encode business logic into the communication. Commonly supported languages include Active Server Pages - ASP, Javascript, PHP, Python and Ruby.

A web server might also cache content to speed delivery of commonly requested content. This process is also known as web acceleration.

A web server can host a single website or multiple websites using the same software and hardware resources, which is known as virtual hosting. Web servers can also limit the speed of response to different clients so as to prevent a single client from dominating resources that are better used to satisfy requests from a large number of clients.

While web servers typically host websites that are accessible on the Internet, they can also be used to communicate between web clients and servers in local area networks such as a company’s intranet. A web server can even be embedded in a device such a digital camera so that the users can communicate with the device via any commonly available Web browser.

Any computer can be turned into a web server by installing server software and connecting the machine to the Internet. There are many web server software applications, including public domain software from NCSA, Apache, NGINX and commercial packages from Microsoft, Netscape and others.

How do web servers work?

Typically, users visit a website by either clicking on a hyperlink that brings them to that site or keying the site's URL directly into the address bar of a browser. But how does the same site appear on anyone's computer anywhere in the world and often on many computers at the same time?

Let's use JoomTut as an example. You decide to visit JoomTut website by typing its URL https://www.joomtut.com or simply joomtut.com into your web browser. Through an internet connection, your browser initiates a connection to the web server that is storing the JoomTut website's files by first converting the domain name into an IP address through a domain name service DNS and then locating the server that is storing the information for that IP address.

The web server stores all of the files necessary to display JoomTut's pages on your computer typically all the individual pages that comprise the entirety of a website, any images/graphic files and any scripts that make dynamic elements of the site function.

Once contact has been made, the browser requests the data from the web server, and using HTTP or HTTPS, the server delivers the data back to your browser. The browser in turn converts or formats, the computer languages that the files are made up of into what you see displayed in your browser. In the same way the server can send the files to many client computers at the same time, allowing multiple clients to view the same page simultaneously.

Shared IP and Dedicated IP Address

Every domain name that is a home to a website has an IP address assigned to it. An IP address is the real address of a website. Domain names were developed because it is difficult to remember long IP numbers like 123.456.78.9

Shared IP

A shared IP is an IP address that is used for multiple sites. A shared IP can host most or all sites on a web server. Because the IP address of a website is used for multiple sites on the server, the actions of one site owner can affect the IP reputation of everyone sharing that IP on the server. For example, if an IP address is blacklisted for sending SPAM email, this will blacklist mail for all sites using that shared IP address. As your partner in hosting, we work hard to prevent and to resolve these issues immediately and take corrective action against anyone who abuses the system. However, the administrator of a blacklist is the sole authority to decide when to de-list an offending IP.

Many site owners are able to host their site on a shared IP without ever being affected by another site hosted on the server. If mail is critical and you use our mail services, we recommend a dedicated IP address so that your reputation is affected only by the actions of users on your domain.

Dedicated IP

A dedicated IP is an IP address that is assigned to one site. Large websites or e-commerce sites often use a dedicated IP address to have full control over the reputation of their IP. Ecommerce sites must use SSL and therefore a dedicated IP address is often recommended although not required.

What is the web hosting?

A web host is mostly called a space in which you purchase on a web server to store your site files. Think for example your computer and the folders and files in them; every file has a folder in which it is saved and can be accessed easily from, that is just the concept of web hosting.

For any website to become live, it needs to be located, that is hosted on a web server. By buying a hosting plan from any web hosting company, you are only renting space from their web server. So in the situation, someone decides to visit your website by entering your domain name, the person will be directed to your website.

When you hire the services of a web host provider, all back-end concerns would be managed by them, repair and maintenance of the server are included. Generally, a web hosting company is there to make life easier by saying webmasters from lots of hassle.

If you have in mind to start a Joomla! web project and have been evaluating different options to host it, you will have discovered that there is an excellent variety of hosting types.

Now, we explain briefly what each one consists of:

Shared Hosting

Since web hosting can be simply said to be a computer - server that allows you to store and publish your files on the internet for everyone to see. A web hosting company most times called web host can decide to rent its computer - server space to customers.

A shared hosting can then be explained as type of web hosting service where many websites that differs share one physical server. This however reduces the cost of hosting effectively. Even though shared hosting means shared resources like the disk space, ram, CPU and bandwidth, all your files are safely protected from others.

  • Pros
    • It is budget friendly
    • It is very convenient
    • Easy to use
  • Cons
    • ​You have limited resources
    • You don't have full control
    • Shared IP
  • Use Case
    Shared hosting is mostly used by these category of websites
    • ​Low traffic website
    • A new growing website
    • A personal blog
    • A forum

Virtual Private Server - VPS

A Virtual Private Server is simply explained as a virtual machine which takes care of the individual needs of a user, and it is carried out as an isolated physical computer dedicated to one particular user. Virtual servers mostly consist of a file transfer protocol software, a web server software, a mail server program and different other types of software for E-commerce, blogging etc.

You should also note that is this type of hosting; you will be responsible of catering for the server. In summary, a Virtual Private Server is partitioned/mapped out part of a physical server.

  • Pros
    • ​You have full control over it
    • It is more protected and secure
    • You can run scheduled task and maintenance.
    • Dedicated IP
  • Cons
    • It is more expensive than share host
    • You must install the application yourself
    • There is very little support for you
  • Use Cases
    • Low to medium traffic website
    • A new growing website
    • Advanced users
    • Small companies and businesses

Cloud Server

Cloud servers are often confused with the VPS, as both are based on virtualization and come with many of the same advantages. Much of the definition, however, depends on the particular host provider. In dedicated servers and most virtual private servers, the storage disks and the processing power are all on one physical host machine, but with some other the storage backend and the compute nodes are run separately. This provides many advantages such as easy scalability and redundancy through automation over the traditional virtualization platforms while still guaranteeing a highly competitive performance and pricing.

  • Pros
    • Better uptime, high availability
    • Scalability and flexibility
    • ​You have full control over it
    • It is more protected and secure
    • You can run scheduled task and maintenance.
    • Dedicated IP
  • Cons
    • It is more expensive than VPS
    • You must install the application yourself
    • There is very little support for you
  • Use Cases
    • Advanced users
    • Medium companies and businesses

Dedicated Server

Dedicated servers offer close to metal implementation with little overhead, and they’ve been traditionally the go-to-solution for high performance demanding tasks. As the name implies, each server is dedicated privately to one client. The customer receives access to a physical server with the agreed upon hardware specifications, processing and storage, all in one unit.

  • Pros
    • Powerful server
    • ​You have full control over it
    • It is more protected and secure
    • You can run scheduled task and maintenance.
    • Dedicated IP
  • Cons
    • It is more expensive than all
    • You must install the application yourself
    • There is very little support for you
  • Use Cases
    • Advanced users
    • Large companies and businesses