Web server
A web server is software, and by extension the computer running it, that receives requests from browsers over the internet and responds by sending back web pages, images, files or error messages.
The term is used for two things: the physical or virtual machine, and the program on it that handles web traffic. When developers say "the web server", they usually mean the program, such as Apache, Nginx or LiteSpeed. Web hosting is the service of renting space on such machines; the web server is the part that actually answers each visitor.
A web server is also not the same as the application. On a WordPress site, the web server receives the request and passes it to PHP, which runs WordPress, which asks the database for content. The web server then sends the finished page back. If any link in that chain fails, the visitor sees an error.
How it works
Every visit starts with a request. The browser connects to the server's address, normally on port 443 for HTTPS or port 80 for plain HTTP, and asks for a specific path, such as /contact/. The web server checks its configuration to decide what that path means: a file on disk, a redirect, a request to hand to an application, or something forbidden.
It then sends back a response with a status code and the content. Status code 200 means success, 301 means the page has moved permanently, 404 means not found and 500 means something failed on the server. Headers sent alongside tell the browser how long it may cache the file, what type of content it is and which security rules apply.
Configuration differs by server. Apache and LiteSpeed read per-folder rules from a file called .htaccess, which is how many hosts let customers set redirects; Nginx does not use .htaccess, so the same rules must be written into its main configuration. That difference is why a redirect that worked on one host can silently stop working after a move.
Example
A visitor opens a garden company's page about hedge trimming. The web server sees the request, notices the address has no trailing slash, sends a 301 redirect to the version with one, then receives the second request and hands it to PHP. The page is built, the server attaches headers telling the browser it may keep the logo for a year, and the whole exchange completes in well under a second.
When the owner later renames the page, the developer adds a 301 rule on the web server so the old address forwards to the new one. Anyone can check this kind of behaviour with a free online HTTP header checker: paste the old address and it shows the status code and where it leads.
Why it matters for your business
The web server's configuration controls speed, security and search engine behaviour more than most owners realise. Compression, caching headers, redirects and security headers are all set here, and a few lines can make the difference between a fast, well-indexed site and one that loads slowly or leaks old pages. Most small businesses never touch it directly, which is fine, but someone responsible for the site should know which server software it runs and where its rules live.
Common mistakes
- Copying .htaccess rules to a server running Nginx and assuming they still apply.
- Leaving directory listing switched on, so visitors can browse folders that have no index page.
- Fixing a 500 error by trial and error instead of reading the server's error log.
- Ignoring the status codes old URLs return after a redesign, so they show 404 instead of redirecting.
Questions people ask
What is the difference between a web server and web hosting?
A web server is the software and machine that answers browser requests. Web hosting is the service of renting space and resources on web servers, usually with extras such as email, backups and a control panel. Your host runs the web server so you do not have to.
Which web server is best for a small business site?
For most small sites it hardly matters, because the host chooses and manages it. Apache, Nginx and LiteSpeed all serve small sites well. What matters more is that the server is kept updated, configured with compression and caching, and that your developer knows which one it is.
How can I see what web server my site uses?
Open your site in a browser, open the developer tools, reload the page and look at the response headers for the main document. A header called server often names the software, though many hosts hide or change it for security. Your host's documentation will also say.