Web Servers and Hosting
In 1989, the first web server, known as CERN httpd, was created, along with a browser called WorldWideWeb.
As people began to realize the effectiveness of transferring data across what is now known as the internet, multiple operating systems began to develop so that all industries, and eventually the public, could exchange data using computers.
If you run a website, it is important to understand what web servers are, how they operate, and what role they play in delivering your website content to site visitors.
After all, without web servers, no one would be able to access your website.
What is a Web Server?
It’s possible you’ve never thought about what happens when you enter a URL into your computer’s browser or click on a website found in a search result. In fact, you may just think that when websites appear on your computer screen, it is the result of some kind of technological magic.
And for the most part, this is okay if you are a casual internet user who enjoys simply browsing and finding information that interests you.
Importance of Understanding How Servers Work
However, if you run your own website, understanding web servers is crucial to your success.
This knowledge will help you have a better understanding of how your site’s data is delivered to site visitors and even help you choose the right web hosting company to store all of your site’s data.
Web servers are programs that use HTTP (Hypertext Transfer Protocol) to serve the files that form web pages, such as the ones that make up your website, to site visitors when they click on your site or enter your site’s URL into their web browser.
They can deliver the same files, or different ones, to hundreds of site visitors at any given time.
They are also a part of a larger web of programs that help serve emails, download File Transfer Protocol (FTP) files, and build and publish web pages such as the ones you have on your site.
What Operating Systems do Servers Use?
Servers typically run on one of two operating systems, Linux or Microsoft Windows.
The most popular operating systems to run web servers on is Linux, which is what most hosting companies do.
You can, however, find some web hosts that will host your site using the Windows operating system.
There are two different kinds of web servers to be aware of: hardware servers and software servers.
Unfortunately, there is not always a clear distinction between the two, which makes things confusing for people that don’t understand what servers are and how they work.
A hardware server is the actual computer that stores your website data and delivers it to site visitors when they request it by clicking on your website.
These large computers are housed in datacenters that are manned by a security team and other security measures such as video surveillance.
Datacenters are based all around the world. This makes delivering site content to an international audience easier if your site’s data is stored on a server that is located near your target audience.
That’s because the closer the web server is to the site visitor requesting to see your website, the faster it can deliver that request.
What Are Software Servers?
Software servers are the software programs that run in the background with the help of the Linux or Microsoft Windows operating systems.
For example, the HTTP server is responsible for sending website files to site visitors because it has the ability to understand URLs and HTTP protocols the browser uses to view web pages and deliver content to site visitors.
In addition, the FTP server allows for the uploading of files, and the database server stores important information related to your website, such as the customer data needed to run an ecommerce shop and process transactions.
What Role Do Content Management Systems (CMSs) Play?
Lastly, there is software that runs in the background that requires the use of usernames and passwords to access.
This includes popular content management systems (CMSs) such as WordPress.
The important thing to remember is that software “servers” are actually just software programs aiding in the delivery of site content to visitors.
Used correctly, the term web server actually means the physical computer housing the program that stores your website’s data.
How Web Servers Work
Now that you have a good idea what a web server is, it is time to take a look at how they work so you know how your website is being delivered to interested site visitors.
Every bit of data that makes up your website is stored on physical web servers for safekeeping.
When someone requests to see your web pages, either by clicking on your website in a search result or by entering the URL, a request is sent to your web server asking for that data.
How Browsers Work
While this is happening, the browser your site visitor is using, such as Firefox, Chrome, or Internet Explorer, must find the server that your site’s data is located on.
If it has contacted your server in the past, this process is easy, especially if your web content is cached.
However, if the browser does not know where your server is, it may need to look up its IP address in the Domain Name System.
Either way, the browser will find your server and read the request that was sent by the site visitor to see your website.
How Web Servers Send Data
Your web server receives all requests to see your website and handles them according to the web server’s configuration files.
This may mean delivering static files to a site visitor or enabling another application and waiting for a response from it.
Regardless, all requests to see your website are written in HTML text, which is a programming language that tells the computer browser how a website should be formatted.
Making Data User-Friendly
However, if you received the HTML text on your computer screen as a site visitor requesting to see a website, you wouldn’t understand it.
That’s why the browser must rearrange the HTML text into a readable form, which site visitors see as written text and images.
Web Server Optimization
Your web server plays a crucial role in displaying your website to site visitors.
Without the web server housing all of your site’s data, site visitors would not be able to access your content at all.
It is important that your web server performs well so it can deliver site content to visitors as quickly as possible.
Here are some of the best ways to ensure your server is giving site visitors the best user experience possible.
Web Server Content Caching
Caching your site’s static content, which is content that doesn’t change that often, is a great way to make the delivery of site content to people faster.
If your web server stores static content in its active memory, any request to see that content by site visitors is delivered instantly, eliminating the need for the site visitor’s browser to rearrange that content into readable form.
Companies that offer this type of service are called content delivery networks.
Web Server Configuration
There are several different types of web servers available to store your site’s data on.
Some require specific operating systems to run on, and some can run on any operating system, though the popular ones are still Linux and Windows.
Currently, the two most popular web servers are Apache web servers, which come as a software stack including Linux, Apache, MySQL, and PHP (LAMP), and the Microsoft IIS (Internet Information Server).
There are also other web servers such as NGNIX, Google Web Server (GWS), and IBM’s Domino servers.
No matter which web server your hosting company uses, there are ways to optimize them to perform at top speeds:
- Rewrite request details before sending them to secondary applications
- Block requests by certain IP addresses
- Serve different content based on referring websites, mainly to prevent hotlinking.
How Do Web Servers Relate to Web Hosting?
Web hosting is the process of storing all of the files that make up your website. Web hosting companies store your site’s data on web servers and, as a result, aid in delivering site content to site visitors.
Hosting services usually consist of all maintenance related to the server itself, including backups, root configurations, disaster recoveries, security, and uptime.
There are cases, however, depending on the hosting plan you choose, which allow you to have more control over the server storing your website’s files, including all related maintenance issues.
Different Types of Hosting
For example, if you choose a dedicated server hosting plan, in which you rent an entire server to store your site’s data on, you will have control over the operating system, hardware, and software used on it.
You will also be able to store an enormous amount of data without worrying about running out of server resources.
What to Consider When Choosing a Host
Just keep in mind that when you use inexpensive hosting plans, the amount of server resources available are limited and are shared by other website owners whose site data is stored on the same server as yours.
In the end, no matter which hosting plan you go with, know that your website’s data is being housed on large computers called servers that use specialized, built-in programs to deliver your website’s content to those that request to see it.
Frequently Asked Questions About Web Server
How does a web server compare to a data server?
While a web server handles HTTP requests and exchanges documents over the network, a data server takes similar requests, but instead of sending documents, it sends data.
Usually, a web server will communicate with a data server to store or retrieve information, rather than allowing the visiting user direct access to the data server.
How does a web server relate to the “cloud?”
For a cloud hosted website, the cloud provider is usually controlling the web server and parts of the web application – unless the customer is using a “Virtual Server” – which is an emulated computer that exists inside of a higher rooted computer.
The term cloud can also apply to a normal web host, so with any cloud provider, just be sure to know whether you’re buying a server or an application on a server.
What is the difference between a website and web application – and how does it affect a web server?
The line between a website and web application is blurry, but usually a web application is constructed dynamically based on user input.
Anytime a website has a user login system, that’s an indicator that there is a more complex “application” running at the web address it appears on.
Sometimes a web application will talk very closely with the web server, to make sure that when you visit a particular part of the site, certain information related to the user gets sent out to each individual user.
So, if you were to visit a profile page, the web application would know to send back your profile information.
What is a web port and how are they used?
Every web server runs data packets through a pre-designated “port” which is associated with a computer’s network driver. By default, websites most commonly use port 80 and are not seen when browsing to a website. However, a web port can be accessed by typing : and a number.
So, if you run a web server on your computer, you can tell it to run at localhost:8080, where 8080 is the port and localhost is the friendly name for a computer’s “home” address. Ports are useful for setting up fast data streams, running multiple web servers simultaneously, or for using network protocols for software other than a web browser, such as Skype.
How do I install a web server?
This depends drastically based on the operating system and web server application in question. For a Windows IIS server, sometimes the software comes pre-installed. The same is true of certain Java machines or Linux machines, which might come pre-installed with Apache.
Some web servers can be installed via command line in programming languages/interfaces like Python or NodeJS. Ruby on Rails usually comes with Mongrel or Passenger, and almost every programming language will have a most commonly used web server. Each one will require special installation and appreciation of web ports.
Does operating system matter to a web server?
Viewing content on a website doesn’t require a user to have the same operating system as the website. However, for the administrator of that website, a web server must be chosen which is supported by the operating system of the computer which the web server is running on.
To make things more confusing, the computer itself is also called a “server” – so you have a web server running on top of the “server” computer. The web server itself is a piece of software, and that software needs to be compatible with the operating system.
Need a great web host? Want to save some time? This shortlist is your best place to begin: