Deploy a Static Site to Cloudflare Pages
Micropage turns page markup into a static site and hosts it for you on Cloudflare’s network. If you would rather run the site from your own Cloudflare account, every build can be downloaded as a static .zip and deployed to Cloudflare Pages in two commands.
The basic pipeline
At a high level:
- write page markup
- save or push content
- Micropage parses the markup and creates a build
- the build generates static HTML, CSS and assets
- Micropage publishes it at
{your-project}.micropage.sh(or your custom domain)
Every build is also downloadable, which is what makes the Cloudflare Pages route possible.
Web App flow
In the Web App:
- open a project
- edit content in the editor
- click Save to create a draft build (the live site does not change)
- click Publish to deploy the current markup
CLI flow
From the CLI:
micropage push
micropage publish
Use push to save a draft build without deploying. Use publish to build and deploy immediately.
Deploying to your own Cloudflare Pages project
On Pro, download any build as a zip. The archive holds the generated site at its root, with relative links so it also works opened straight from disk:
micropage builds download --output site.zip
unzip site.zip -d site
npx wrangler pages deploy site --project-name my-site
The first wrangler run asks you to log in to Cloudflare and creates the Pages project if it does not exist. After that the site is live at my-site.pages.dev, and you can attach your own domain in the Pages dashboard.
To keep it updated, run the same three commands after each publish, or put them in CI. A GitHub Actions job with a CLOUDFLARE_API_TOKEN secret (Pages Edit) and CLOUDFLARE_ACCOUNT_ID works the same way, with wrangler reading both from the environment.
The .page source is yours on every plan, and the zip is plain HTML, so the same archive also runs on Netlify, S3 or your own server.
One thing stays tied to Micropage hosting: form spam protection. Its Turnstile check only accepts the site’s own Micropage hostnames, so forms on a self-hosted copy won’t validate. Pages, styling, posts and RSS all work as they do on the hosted site.
Why builds matter
A build gives you a versioned snapshot of the site. That means you can always know:
- what is currently live
- what is still a draft
- whether you can redeploy an older version
Redeploying a previous version
If needed, you can redeploy an older build:
micropage builds redeploy 3
This rolls the hosted site back to that version without editing content again. The CLI marks it as the active build and republishes it (it does not create a new version number). To roll back a site you host on Pages, download that version instead: micropage builds download 3 --output site.zip.
You can also redeploy from the Builds tab in the Web App.
Custom domains
Sites hosted by Micropage are available at {your-project}.micropage.sh, and you can connect your own domain with a CNAME record. See Custom Domains for setup instructions.