Web Server
The program that listens for HTTP requests and answers them with files or generated pages, from the first one at CERN in 1990 through Apache's long dominance to event-driven servers built to hold many thousands of connections at once.
A web server is a program that waits for requests from browsers and other clients, then answers them. A request names a path; the server responds with a file from disk, a page generated by a program, or an error code. The same name often refers to the machine running it, but the software is what defines the role.
The first was written by Tim Berners-Lee at CERN in 1990, alongside the first browser. The NCSA server at the University of Illinois became the most popular in the early web, and it introduced a way to run external programs to build pages on demand. When its development stalled, a group of administrators pooled their fixes into a new release in 1995. That became the Apache HTTP Server, which ran most of the world's websites for over a decade and grew a foundation around it. Paired with Linux, a database and a scripting language, it formed a standard stack for cheap dynamic sites; see LAMP stack.
A server has to tell clients what kind of content it's sending, so it labels each response with a type such as an image or a page; see MIME Type. Virtual hosting lets one server and one address serve many sites. Browsers send the site name with every request, and the server picks which site to answer for, which is how a single cheap machine can host thousands of domains.
How a server handles many visitors at once has shaped its design. Apache's classic model gave each connection its own Process or thread, simple and robust but memory-hungry, since thousands of idle connections meant thousands of idle workers; see Thread Pool. In 1999 an engineer framed this as the challenge of handling ten thousand simultaneous clients on one machine. Nginx, released publicly in 2004, answered with an event-driven design: a few workers each juggle thousands of connections, reacting whenever one is ready; see Event Loop. By several surveys it later overtook Apache as the most widely used server. Node.js later brought the same approach to application code.
Modern deployments often stack servers. A front server terminates encryption, serves static files and caches, and passes everything else to application servers behind it; see Reverse Proxy. Encryption used to require buying certificates and installing them by hand; free automated certificates, available since 2015, made HTTPS the default; see Let's Encrypt.
A server also keeps records. Access logs listing every request, its status and its size, in a format dating back to the NCSA server, were the web's first analytics, and remain essential for debugging and security.
See also2
Linked from10
- Certificate AuthorityNetworks & Distribution
An organization trusted to vouch that a public key belongs to a domain or entity, the root of trust behind every HTTPS padlock.
- DaemonSystems & Tooling
A long-running background process managed by the operating system's service supervisor.
- Event LoopComputation & Algorithms
A single-threaded runtime's mechanism for pulling the next callback off a queue once the call stack is empty.
- HTTP CachingWeb Platform
The set of headers that let a browser or intermediary reuse a previous response instead of re-fetching it.
- MIME TypeWeb Platform
The short type/subtype label, born in email, that tells a browser how to treat a response, and why browsers that guess when it's missing turned a convenience into a security hole.
- PHPWeb Platform
The server-side language that began in 1994 as a personal set of homepage tools, spread on cheap shared hosting to run much of the web including WordPress and early Facebook, and survived years of ridicule by getting much faster and stricter.
- ProcessSystems & Tooling
A running program with its own memory, environment, and identity.
- Reverse ProxyNetworks & Distribution
A server that sits in front of other servers and receives clients' requests on their behalf, handling encryption, routing, caching, and protection in one place.
- Thread PoolSystems & Tooling
A fixed set of threads kept alive to run many short tasks from a queue, avoiding the cost of creating a thread per task and capping concurrency, with sizing rules and failure modes that shape how servers and runtimes behave under load.
- Web HostingWeb Platform
Renting space on someone else's servers to put a website online, a business that moved from free personal pages and crowded shared machines to virtual servers, rented cloud infrastructure and services that host static files at the edge of the network.