Websites · Glossary
What is a static website?
A static website is a site whose pages are prepared in advance as ready made HTML, CSS and image files and sent to every visitor as they are, rather than being assembled by a server on each visit. Static sites load fast, scale easily and have little to attack, but anything personal or live, such as logins, needs an API or service alongside.
Static describes how pages are delivered, not how they look. A static site can have animation, forms and a shopping cart; it simply does not run server code to build each page.
Nuwan Madhusanka · Co-founder
3 min read · Published
Static versus dynamic
A dynamic site runs code on a server for each request, usually reading a database, then sends the result. A static site does that work once, when it is published, and stores the finished files. Every visitor gets the same files from a server or a CDN, which is why static pages arrive so quickly.
Why static sites are fast and safe
Files can be cached close to visitors on a content delivery network, so there is no wait for a database or page building. With no server code running per request, there is far less to break into, nothing to patch weekly and nothing to slow down when a post goes viral.
How static sites still do live things
Forms post to an API that stores the entry. A cart fetches prices from an API before checkout. A collection of items can be read from an API by a small script in the page. The pages stay static while specific features call services, which keeps most of the speed and security.
What they cannot do on their own
Show each visitor different content after login, run a members area, process anything secret in the page, or update without a new publish unless a script fetches fresh data. For those, a site needs server code or a service built for it.
Where it shows up in OneCraft
Published sites are static files on a CDN, and each publish is a version you can roll back to. Contact and newsletter forms post to an API, the store cart asks the server for prices, and in Code mode data collections are read from an API. There is no server code in published sites, and Code mode output is limited to static file types.
Questions people ask
Are static websites good for SEO?
Yes. Search engines read the ready made HTML directly, pages load quickly, and there is no client side rendering to wait for. Titles, descriptions, sitemaps and structured data work exactly as on any other site. Speed is a small ranking factor and a large factor in whether visitors stay.
Can a static website have a contact form?
Yes. The form is part of the static page, and when submitted it sends the entry to an API that stores it and notifies the owner. The page itself does not need server code; the service behind the form does the work, including spam filtering.
Can a static site have an online store?
Yes, with a store service. Product pages and the cart page are static, while the cart asks an API for current prices and stock, and checkout runs on a payment provider such as Stripe. Stock and price changes can rewrite the affected files without a full rebuild.
Do static websites need hosting?
They need somewhere to serve files from, which is simpler and cheaper than hosting a dynamic application. Many platforms bundle this, storing the files and serving them through a CDN, so the owner never manages a server, installs updates or worries about traffic spikes.
Is WordPress a static website?
A standard WordPress site is dynamic: PHP code builds each page from a database on request, with caching on top to speed it up. Plugins can export a WordPress site to static files, which some owners do for speed and security.
Make one with websites
The button opens the generator with this use case already described. Change the wording to match your own.
Create a website with OneCraftRelated questions
- What is a CDN?What is a CDN? A network of servers around the world that keeps copies of your site files close to visitors, so pages load faster and survive traffic spikes.
- What are Core Web Vitals?What are Core Web Vitals? Three measures of loading, responsiveness and visual stability, LCP, INP and CLS, with the thresholds Google uses and what moves them.
- What is an SSL certificate?What is an SSL certificate? The file that lets a site use HTTPS, proving the domain and encrypting traffic. Why every site needs one and why most are free now.
Written and checked by the OneCraft team. Last checked .