Skip to content

Deployment

MikroCanvas ships as static files and can be served from any host that can deliver HTML, CSS, JavaScript, SVG, and web manifest files. This is the default local-first mode.

Terminal window
curl -sSL -o mikrocanvas.zip https://releases.mikrosuite.com/mikrocanvas_latest.zip
unzip mikrocanvas.zip -d mikrocanvas

Deploy the extracted app files.

  • Serve index.html as the entry point.
  • Keep assets/main.js, assets/styles.css, app-icon.svg, app-icon-192.png, app-icon-512.png, favicon files, and manifest.webmanifest beside it.
  • Use HTTPS for hosted deployments so browser storage and file features behave consistently.

No server API is required for the local-first app.

Run the bundled API server when users should be able to publish board snapshots and open them by ID:

Terminal window
npm start

The server stores published snapshots in SQLite and serves config.json with API mode enabled. A board URL includes ?board=<id>, and anyone with that ID can load the published snapshot locally.

Publish the active board snapshot from the top-bar link button or from the command palette. Local edits are not uploaded again until the user publishes another snapshot.

Configure an optional admin token if operators need recovery deletion for remote snapshots.

Use mikrocanvas.config.json, environment variables, or CLI flags to set the host, port, app URL, database path, and optional admin token. See mikrocanvas.config.json.example for the file shape.

Cloudflare Pages builds set CF_PAGES=1, so MikroCanvas emits dist/config.json with API-backed snapshots enabled and apiBaseUrl set to https://canvas-api.mikrosuite.com.

Set MIKROCANVAS_PUBLIC_API_BASE_URL in the Pages build environment to override that API origin.