Learning objectives
After reading this article you will be able to:
- Understand what goes into the cost of a static site
- Estimate your site's monthly traffic with a simple formula
- Compare no-cost tiers and paid plans by billing model
A static site is just a set of ready-made files: HTML, CSS, JavaScript, images and fonts. A web server just hands those files over: none of your code builds pages on every visit, and no database has to stay online. That makes it the cheapest kind of site to host, and the monthly hosting bill is often zero. What changes the math is how much your visitors download.
If you are not sure your project is static, read what a static site is. For sites with a server, a database or an admin panel, the math is different and lives in how much website hosting costs. Third-party prices and quotas change often, so this guide gives you the method. The numbers in this article are hypothetical, chosen to make the math easy. They are not any provider's prices; real values live on the official pricing pages.
What goes into the cost of a static site?#
Four items, almost always billed in different ways:
- Data transfer (bandwidth): the GB that leave the provider for browsers. It is the item that grows most as the site takes off.
- Requests: every downloaded file counts as one. A page with 25 images, scripts and fonts makes dozens of requests per visit.
- Builds and deploys: if the platform builds the site from your repository, it may limit or charge for build minutes and deploy counts.
- Domain: your own address, paid to a registrar every year. See how much a domain name costs.
Storage hardly ever matters: a typical static site takes a few MB, far from any quota. The HTTPS certificate is usually free of charge too, because platforms issue certificates automatically.
How do you estimate your site's traffic?#
The basic formula is:
monthly transfer (GB) = average visit weight (MB) × visits per month ÷ 1000Example: a portfolio with 1.5 MB pages and 20,000 visits a month uses about 30 GB. A blog with 200,000 visits and the same page weight reaches 300 GB.
To measure page weight, open the page in your browser, use the developer tools (Network tab) and read the total transferred with the cache disabled. That is the worst case: returning visitors download less, because the browser keeps CSS, scripts and images. Use the worst case so the bill does not surprise you.
For requests, multiply visits by the number of files on a page. 20,000 visits with 30 files each come to 600,000 requests a month.
How far do the no-cost options go?#
Every option below serves a static site without charging anything, within limits. The size of each quota is on the provider's page:
| Option | What it limits | Watch out for |
|---|---|---|
| GitHub Pages | site size, monthly bandwidth (soft limit) and builds per hour | no sites mainly aimed at commercial transactions |
| Cloudflare Pages | builds per month, files per site and the size of each file | server-side functions count toward the Workers quota |
| Netlify Free | monthly credits, spent on bandwidth, requests and deploys | bandwidth alone can use up the credits with little traffic |
| Vercel Hobby | transfer and CDN requests per month | personal, non-commercial use only; no extra usage for sale |
| Firebase Hosting (Spark) | storage and transfer per day | the daily quota caps the monthly total |
| Amazon CloudFront (Free flat-rate plan) | requests, transfer and S3 storage per month | you set up the bucket and distribution yourself |
To know whether the 30 GB portfolio in the example fits, compare your estimate with each option's quota. Watch two formats that mislead. Daily quotas must be multiplied by 30: assuming 300 MB a day (a hypothetical figure), the month allows only about 9 GB. Credit quotas must be turned into GB: assuming 200 credits a month and 10 credits per GB, bandwidth alone uses up the quota at 20 GB, below the 30 GB in the example.
How much does it cost when the site grows?#
When traffic outgrows the quota or the site becomes a business, paid plans come in:
| Option | Billing model | What to watch |
|---|---|---|
| Netlify (paid plans) | monthly fee with a credit allowance | how many GB the credits cover if all of it goes to bandwidth |
| Vercel Pro | monthly fee per seat, with a transfer and request quota | the price of each GB of overage |
| Firebase Hosting (Blaze) | pay as you go, beyond the no-cost quota | the price per GB transferred and per GB stored |
| Amazon CloudFront (flat-rate plans) | monthly fee with a request and transfer quota | what happens when you pass the quota |
| Cloudflare Workers Paid | monthly minimum for server-side code | whether static assets are billed |
Here is the math for a site with 100 GB a month, 1.5 MB pages and 20 files per visit (about 67,000 visits and 1.3 million requests), with hypothetical prices:
- Credit-based plan: assuming 10 credits per GB and 1 per 10,000 requests, that is 100 GB × 10 = 1,000 bandwidth credits, plus about 133 request credits. Around 1,133 credits in total: the plan you pick has to include at least that.
- Pay-as-you-go plan: assuming $0.10 per GB beyond a no-cost quota of 9 GB a month, (100 − 9) GB × $0.10 = $9.10 a month.
- Fixed-quota plan: fits in the no-cost tier if the site is non-commercial and the transfer quota is above 100 GB; if it is commercial, the paid plan's monthly fee applies.
The same site can cost zero or a full monthly fee depending on the provider and the use case. That is why the traffic estimate comes before the choice. To compare criteria beyond price, see how to choose a hosting provider.
What are the hidden costs?#
- Commercial use on a personal plan: a store or a client's landing page does not belong on a non-commercial tier. Switching plans in a hurry costs more.
- Traffic spikes: a viral post or a wave of bots can blow through the quota. On usage-based plans the bill goes up; on capped plans the site may go offline until the month resets.
- Features beyond static files: forms, server-side functions, image optimization and visitor analytics often have their own quotas, billed separately.
- Builds: large sites built with a static site generator can burn through build quotas or deploy credits.
- Currency conversion: if your card is not in US dollars, your bank adds the exchange rate and often a foreign transaction fee.
How do you pay less for the same site?#
The fastest win is a lighter visit. Images make up most of the traffic on most sites: convert them to WebP or AVIF and serve them at the size they appear on screen. Remove fonts and scripts you do not use.
Next, use caching. Files with a hash in the name (such as app.3f9a2c.js) can get a long Cache-Control, so returning visitors do not download everything again. See what Cache-Control is. A CDN serves files close to the visitor and usually comes included with the platforms above.
Finally, move large files out of the site. Videos and heavy downloads are better served by a video service or object storage than by eating into your site host's bandwidth quota.
How to do this on Square Cloud#
On Square Cloud, the GB and request math in this article doesn't change the price. Traffic is unlimited on every plan, with no per-bandwidth or per-request charges (fair-use policy): you pay the plan's fee, billed in Brazilian reais, by Pix or card. Every plan is paid; Hobby starts at R$12.49 a month, with 1 GB of RAM, and covers bots and sites.
Among several runtimes, such as Node.js, Python and Go, there is one for static sites. On it, nginx is always online serving your files and none of your code runs on the server, so the site fits in the minimum for a web app, 512 MB of the plan's RAM pool. There are no build minutes to pay for either: the platform has no build step, so you build the folder on your machine or in CI and upload it as a ZIP, with the CLI or from GitHub. A new commit, an upload or an edit in the file manager goes live right away, with no restart. See the runtimes available today on Runtimes.
Every plan includes a global CDN, automatic TLS and cookieless web analytics with visits, routes and countries, a feature that, as you saw above, often has its own quota elsewhere. Every web app gets a *.squareweb.app subdomain with HTTPS; custom domains start on Standard (R$44.99 a month), with the DNS records the dashboard shows created at your registrar. To publish, start with the static sites runtime.
Website hosting
Static and SSR sites with automatic TLS and a global CDN
FAQs
Can I host a static site without paying anything?
Yes. GitHub Pages, Cloudflare Pages, Netlify, Vercel and Firebase Hosting all have no-cost tiers for static sites. Each has limits on traffic, builds or commercial use, so read the terms first.
How much traffic does a small static site use?
Multiply the average weight of a visit by the number of visits. A site with 1.5 MB pages and 20,000 visits a month uses about 30 GB, or less when browsers cache the files.
Can I use a no-cost tier for a commercial site?
It depends on the provider. Vercel's Hobby plan is for personal, non-commercial use only, and GitHub Pages does not allow sites mainly aimed at commercial transactions or e-commerce.
Is the domain included in the hosting price?
Almost never. You pay for the domain separately, to a registrar, every year. The HTTPS certificate, on the other hand, is usually issued at no cost by the host.
More in Websites
See all 20 articles- What is a static site (and how to host one)A static site is a set of ready-made HTML, CSS and JavaScript files served the same to every visitor. Learn how it works, when to use one and how to host it.
- How much does it cost to host a website?Hosting a website costs anywhere from nothing to a few dozen dollars a month. See what goes into the bill: hosting, domain, traffic and extras, with real limits.
- What is a web server? Nginx, Apache and Node explainedA web server is the software that receives HTTP requests and returns pages, files or API responses. Learn how it works and when to use Nginx, Apache or Node.js.
- Static vs dynamic website: differences and when to use eachA static website serves ready-made files, the same for everyone; a dynamic one builds each page per request. Compare speed, cost, security, SEO and use cases.