Zola
Zola is a fast static site generator written in Rust. It outputs a fully static site to public/ by default. Since Zola has no build plugin system, pageflare integrates as a post-build step — chain it after zola build in your build command or CI pipeline.
Install
Section titled “Install”# Shell (Linux/macOS)curl -fsSL https://get.appz.dev/pageflare/install.sh | sh
# Homebrewbrew tap getappz/tap && brew install pageflare
# npmnpm install -g @pageflare/cliRun pageflare after Zola builds:
zola build && pageflare public/ --in-placeConfiguration
Section titled “Configuration”Create a pageflare.jsonc in your project root to customize behavior:
{ "minify_html": true, "minify_css": true, "minify_js": true, "js_defer": true, "lazy_images": true, "img_dimensions": true, "font_swap": true, "preconnect_hints": true}If you use a custom output dir (zola build -o build/), pass the same path to pageflare:
zola build -o build && pageflare build/ --in-placeCI/CD Integration
Section titled “CI/CD Integration”GitHub Actions
Section titled “GitHub Actions”- name: Build Zola run: zola build
- name: Optimize with pageflare uses: getappz/pageflare-cli@v1 with: args: "public/ --in-place"Netlify
Section titled “Netlify”[build] command = "zola build && pageflare public/ --in-place --no-progress" publish = "public"Vercel
Section titled “Vercel”{ "buildCommand": "zola build && pageflare public/ --in-place --no-progress"}Cloudflare Pages
Section titled “Cloudflare Pages”[site] bucket = "./public"Build command: zola build && pageflare public/ --in-place --no-progress
What pageflare Adds
Section titled “What pageflare Adds”Zola handles Sass compilation and basic asset colocation, but does not optimize the final output. pageflare adds:
- HTML, CSS, and JS minification
- Lazy loading and image dimension inference
- JavaScript defer and loader injection
- Font display swap and self-hosting
- Preconnect hints for third-party origins
- Critical CSS extraction (Pro)
- Responsive image srcset generation (Pro)
What Zola doesn’t cover
Section titled “What Zola doesn’t cover”Zola focuses on content and templating — it doesn’t optimize output. pageflare adds:
- HTML, CSS, and JS minification
- Lazy loading and image dimension inference
- Font display swap and self-hosting
- Preconnect hints
- Critical CSS extraction (Pro)
- Responsive image srcset (Pro)
Pro License
Section titled “Pro License”Set the PAGEFLARE_LICENSE environment variable to unlock Pro optimizations:
PAGEFLARE_LICENSE=your-key zola build && pageflare public/ --in-placeDeploying
Section titled “Deploying”Zola static output works with any hosting provider:
- Vercel — automatic Vercel Image Optimization
- Netlify — automatic Netlify Image CDN
- Cloudflare Pages — Cloudflare Image Resizing
- Self-hosted — any static file server
Troubleshooting
Section titled “Troubleshooting”pageflare processes 0 files
Make sure Zola has finished building before pageflare runs. Use && (not &) to chain commands. Verify the output directory — Zola defaults to public/ but this changes with the -o flag.
CSS not minified
If Zola’s Sass output is already minified via [build] config in config.toml, pageflare will still process it but savings will be minimal. Both can run safely together.
Slow builds on large sites
Zola builds are fast, but pageflare’s image processing can add time for sites with thousands of images. Use --force to skip incremental caching in CI, or run with --log info to see per-phase timing.