What Is Web Hosting?
Infrastructure Editor
Disclosure: Some links on this page are affiliate links — if you sign up through one, we may earn a commission at no extra cost to you. It never changes our ratings, rankings or verdicts: we don't sell hosting and take no pay-for-placement.
Who it's for
- First-time website owners
- Small business owners outsourcing their first site
- Students and career-changers learning web infrastructure
By Marcus Feld, Infrastructure Editor (former data-center systems engineer)
What Is Web Hosting? A Plain Definition
Web hosting is a service that stores a website’s files on a specialized computer, called a web server. That server stays connected to the internet, so anyone with a browser can request and view the site. Buying “hosting” means renting space and computing power on that server. It also includes the technical plumbing behind it: a network connection, an operating system like Linux, and the software needed to turn stored files into a working website. Without hosting, a website’s files would just sit on a personal laptop. They’d be invisible to the rest of the internet the moment that laptop goes offline or loses its connection.
This sounds abstract until it’s tied to something familiar.
The Simplest Analogy: A Website Is a Shop, Hosting Is the Building
Think of a website as a shop and hosting as the commercial property it operates from. A shop needs four walls, an address, electricity, and a lease before customers can walk in. A website needs a server, an IP address, uptime, and a hosting plan before visitors can load a page. Domain registration works like putting a sign with the shop’s name out front. It tells people where to find the shop, but it isn’t the building itself. Buying a domain without hosting is like buying a shop sign and nailing it to an empty lot. There’s nothing behind the sign for a visitor to walk into. That distinction, a name versus the physical premises behind it, is exactly what separates a domain name from hosting. It’s covered in full in domain vs hosting.
How Web Hosting Works: The Web Server
At the center of every hosting setup sits a web server, a computer, or more often a virtual slice of one. It runs server software, most commonly Apache or Nginx, built to listen for requests and answer them. Many hosting plans also bundle cPanel, a control panel that gives a customer a visual way to manage files, email, and databases without touching the command line. How web hosting works, at a basic level, follows this sequence: a visitor types a web address into their browser. The browser looks up which server holds that site. Then the server sends back the requested page. That “looking up” step relies on the Domain Name System, or DNS, which works like a phone book. It translates a human-readable domain into the numeric address a server actually understands, sent back and forth using HTTP. Once the request reaches the right machine, the server pulls the requested files, including HTML, images, scripts, and database records, and assembles a response. The full mechanical sequence, request to response, is broken down step by step in how web hosting works.
Hosting companies exist because running a server well is genuinely hard. It needs a reliable power supply, redundant internet connections, physical security, cooling, and backup systems, often built on fast SSD storage rather than older mechanical drives. It also needs staff monitoring it around the clock. Almost no individual or small business wants to build that infrastructure themselves. So hosting providers build it once, at scale, in facilities called data centers, and rent access to many customers at once.
Types of Web Hosting
Not every website has the same needs. That is why hosting comes in several distinct forms rather than a single product. A five-page portfolio site and a high-traffic online store both need “hosting,” but they need very different amounts of it. The core differences between the types of web hosting come down to a handful of attributes. How much of the server is dedicated to one customer? How isolated is that customer from others on the same machine? How much technical control does the customer have? How does the price scale with usage?
- Shared hosting puts many websites on one server, splitting the cost and the resources among them. It’s cheap, but limited under heavy load.
- VPS hosting partitions a server into isolated virtual machines. Each customer gets guaranteed resources without the cost of a whole physical machine.
- Dedicated hosting hands an entire physical server to one customer, maximizing performance and control.
- Cloud hosting spreads a site across many machines, adding or removing capacity automatically as traffic changes.
Every one of these is a different answer to the same underlying question: how should limited server resources be divided among customers with different needs? The full breakdown of every type, with pricing bands and use-case fit, lives in types of web hosting. A structured way to pick between them is covered in how to choose a web host.
Domain Name, Bandwidth, Storage, and Web Hosting Cost
A domain name is the human-readable address, like example.com, that points to a hosted site. It is bought separately from hosting, though many providers sell both together. Bandwidth is the amount of data a hosting plan allows to move between the server and visitors in a given period. Storage is the amount of disk space, often fast SSD storage, a plan allocates for a site’s files, databases, and email. Web hosting cost varies enormously with these three factors, plus the level of resource isolation a plan provides. A shared plan might run a few dollars a month, while a dedicated server can run into the hundreds.
Related Terms Worth Knowing Early
A handful of terms show up constantly around hosting. It helps to know how they relate to it rather than treat them as synonyms.
Server
The physical or virtual machine that stores files and answers requests. See what a web server is.
Domain name
The human-readable address (like example.com) that points to a hosted site. It is bought separately from hosting, though many providers sell both together.
DNS
The lookup system that connects a domain name to the server hosting it.
Bandwidth
The amount of data a hosting plan allows to move between the server and visitors in a given period.
Uptime
The percentage of time a hosting account’s server is available and responding to requests.
A Concrete Example
Imagine a bakery owner who wants a simple website listing her menu and opening hours. She buys the domain sweetcrumbbakery.com from a domain registrar for about $12 a year. Separately, she signs up for a shared hosting plan for $5 a month. That plan gives her space on a server shared with hundreds of other small sites. She uploads her site’s files — built with a simple website builder — to that hosting account. She then points her domain at the hosting account’s servers using DNS settings, a step covered in how to point a domain to hosting. From that point on, whenever anyone types sweetcrumbbakery.com into a browser, DNS routes the request to her hosting provider’s server. That server sends back her menu page. She never touches a physical machine, never configures a network cable, and never worries about power outages at the data center. That’s the entire value the hosting company provides.
The Most Common Misconception
The single biggest point of confusion for newcomers is treating “domain” and “hosting” as interchangeable, or assuming that buying one automatically includes the other. They’re two separate purchases that happen to be sold as a bundle by many companies, which blurs the line further. A domain is a rented name; hosting is rented server space. Losing sight of that distinction causes real problems. People who let a domain registration lapse are often surprised their website “hosting” also went down. In reality, the hosting was fine, but the address pointing to it disappeared. The reverse also happens. A hosting account gets cancelled, or a plan is downgraded, and the site goes offline even though the domain is still registered and paid for. Because this mix-up is so common, it gets its own dedicated explainer at domain vs hosting.
A second, smaller misconception is assuming all hosting plans are functionally the same and differ only in price. In reality, price differences usually track real differences in resource isolation, performance ceiling, and support — not just markup. A $2-a-month plan and a $200-a-month plan are not competing for the same customer. They’re built for entirely different traffic levels and technical needs.
FAQ
Do I need to know how to code to use web hosting? No. Most hosting providers include control panels, one-click installers for platforms like WordPress, and drag-and-drop site builders. Coding knowledge helps for customization but isn’t required to get a basic site online.
Is web hosting a one-time purchase or a subscription? It’s a recurring subscription, typically billed monthly or annually. The server, bandwidth, and support are ongoing services, not a product bought once. Domain registration is also recurring, usually renewed yearly.
Can I host a website myself instead of paying a provider? Technically yes — it’s called self-hosting. It means running the server on your own hardware and internet connection. It’s rarely practical for a public-facing site because home internet connections and consumer hardware lack the reliability and redundancy of a data center.
What happens if my hosting goes down? Visitors typically see an error page or a “site can’t be reached” message until the server comes back online. Reliable providers publish an uptime guarantee, discussed in what uptime means, and most modern hosts stay online well above 99.9% of the time.