Static Hosting
Static Hosting lets you publish static websites and Single Page Applications (SPAs) directly from DeployHQ. We provision a hostname under *.deployhq-sites.com, store your built files on object storage, and serve them globally via Cloudflare's edge network. There is no server to manage and no infrastructure for you to configure — push to your repository and DeployHQ deploys the latest build.
Static Hosting is currently a beta feature. To use it, enable beta features under Settings > Beta Features on your account.
Getting started
Static Hosting is available as a server type when adding a new server to your project. Select Static Hosting from the protocol picker under the Hosting section.
Provisioning a new site
- Navigate to your project and click New Server
- Enter a name for your server
- Select Static Hosting from the protocol picker
- Choose a subdomain — your site will be served at
<subdomain>.deployhq-sites.com. Subdomains must be unique across all DeployHQ accounts; lowercase letters, numbers, and hyphens only - Set the subdirectory to deploy from — the folder in your repository that contains your built site output (for example,
distfor Vite or Astro,_sitefor Jekyll,buildfor Create React App). Leave blank to deploy from the repository root - Toggle Single Page Application (SPA) mode if your app uses client-side routing (React Router, Vue Router, and similar). When enabled, unknown paths are rewritten to
/index.htmlso the router can handle them - Click Create Server
Your site provisions in the background — usually under a minute. The status updates automatically once it is ready.
Pre-fill from framework detection
When your project has a connected repository, the setup form pre-fills the subdirectory and SPA mode based on the framework we detect in the repository. A purple callout appears at the top of Site Configuration indicating the detected framework — for example, "Next.js detected!" with the recommended dist output directory.
The detection runs in two layers:
- A rule-based check against a small set of public manifest files (
package.json,next.config.js,vite.config.ts, and similar) that runs entirely on our build infrastructure. - For projects the rules cannot classify with confidence, an AI-assisted fallback may classify the framework. Only the same manifest files are sent — never your application source code, environment files, or secrets.
For the full list of files read and the AI-fallback policy, see How DeployHQ detects your project's tech stack.
You can override any pre-filled value before clicking Create Server. Detection is advisory only.
Deploying to your Static Hosting site
Once your site is provisioned and active, deploy to it like any other server in DeployHQ. Push to your repository (or trigger a manual deployment) and we build the site, upload the contents of the subdirectory you configured to object storage, and update the edge routing so the latest version is served immediately.
DeployHQ runs a preflight check before each deploy to confirm that the configured subdirectory matches what the detected framework actually builds to. If there is a mismatch — for example, your server is configured to deploy from the root but the framework builds to dist — the deploy still runs, but the build log includes a warning so you can correct the configuration before the next push.
Atomic and accelerated transfers
These options do not apply to Static Hosting. Files are uploaded directly to object storage and routed through Cloudflare's edge — there is no SSH transfer to optimise. The corresponding options are hidden from the Deployment Options section for Static Hosting servers.
Managing your site
Once provisioned, you can manage your site from the server settings page or from Settings > Hosted Resources.
Renaming the subdomain
You can rename the subdomain of an active site at any time from the site's settings. The new hostname takes effect immediately; the old hostname returns a 404 right away. To prevent accidental rapid renames, each site is limited to one rename every 24 hours.
Changing SPA mode or the subdirectory
You can toggle SPA mode and change the deploy subdirectory from the server settings. Changes take effect on the next deployment.
Suspending and resuming
Static Hosting sites are suspended automatically when your account is suspended (for example, after a trial expires without payment or a renewal payment fails). A suspended site returns a static "site temporarily unavailable" page; the underlying files and configuration are preserved.
Reactivating your account restores the site to its previous active state on its existing hostname.
Deleting a site
To remove a Static Hosting site, delete the server from your project's server list. The underlying hosted resource, the uploaded files, and the Cloudflare routing entries are all removed, and billing for that site stops at the next billing cycle.
Pricing
Each active Static Hosting site is billed at a fixed monthly rate, shown on the Hosted Resources page in your account's currency and on each site's setup form. Pricing is billed monthly as an addon to your DeployHQ subscription.
Suspended sites do not accrue charges. Sites removed mid-month are prorated to the day of removal.
Trial and free tier
Trial accounts can provision one Static Hosting site. To provision additional sites, upgrade to a paid plan.
Templates
Like Managed VPS Hosting, Static Hosting is intentionally not available as a protocol in templates. Templates are configuration blueprints copied into new projects, while a Static Hosting site is a single real resource (hostname, storage prefix, routing record) tied to one account. If you want a starter project that uses an existing Static Hosting site, provision it normally and reuse the project's configuration files when scaffolding the next project.