PHP 8.5 · WebAssembly · zero server

Fold PHP into flat HTML.

A static site generator that turns PHP into fast, dependency-free HTML — no server required. Real PHP templates, compiled to plain HTML by PHP running in WebAssembly, right inside Node.

Read the docs Kirigami on GitHub


You write PHP. It compiles to flat HTML.

A page is a real PHP file — includes, loops, a PHPDOC block that becomes your variables. Kirigami runs a PHP 8.5 runtime entirely in WebAssembly, inside Node, and compiles every page straight to plain HTML at build time. Nothing runs on your server, because there is no server.

src/_index.php

                            /**
                             * @title Home
                             */

                            echo str_htmlesc($tagline);
                        
src/index.html — after `kiri build`

                            <h1>Fold PHP into flat HTML.</h1>
                        

What you get

Real PHP templating

Includes, loops, Markdown, YAML — compiled to clean HTML at build time, not served at runtime.

Integrated asset pipeline

esbuild for JavaScript, Sass for styles, wired in from a single kirigami.yaml.

One-command export

kiri export ships a fully static site, ready for GitHub Pages or any static host — banner and sitemap included.

Instant scaffolding

kiri create clones an official template so a new project starts from something real.

A managed <head>

Stylesheet, bundle, theme guard, SEO metadata and JSON-LD — injected automatically, nothing to hand-wire per page.

Zero native dependencies

Images, the cache, tar extraction — all built on WASM and Node's own standard library, not a compiled binding.


What it needs — and doesn't


Built with itself, in the open

This page is a _index.php file, compiled by the same kiri CLI anyone installs from npm. The site is being built in public, phase by phase — /docs/ is the doc-page model, /ecosystem/ pulls its version numbers live from npm at build time, and more lands as each phase ships.


                        npm install -D @kirigami/kirigami
                        npx kiri watch      # rebuild on save, no server
                        npx kiri export     # production build into dist/