Requirements
- Bun ≥ 1.0 is a runtime dependency. The
pylonserver binary spawns Bun as a child process to run TypeScript functions and render React SSR. Every install path below except Stack0 Cloud needs Bun on the host. - Rust: a recent stable toolchain (edition 2021). You need it only if you build the CLI from source. The prebuilt binary and Docker image need no Rust.
- Node.js ≥ 18 (optional, for client tooling)
Fastest start: scaffold an app
The quickest path to a running full-stack app is the project scaffolder. It needs no global install, because it adds@pylonsync/cli as a dev dependency:
app/). npm run dev runs the bundled CLI. Install the standalone CLI below if you want pylon on your PATH for other projects or CI.
Skip the install: use Stack0 Cloud
If you do not want to manage a binary or a server, Stack0 Cloud hosts the same backend you would run yourself. Sign up at www.pylonsync.com/dashboard, then:Install the CLI
~/.local/bin. It supports Linux and macOS, on x86_64 and arm64. It needs no Rust toolchain.
Verify:
pylon doctor checks that bun, node, and the supporting tooling are available.
Install Bun
Pylon uses Bun to run TypeScript server functions and to bundle the client code generator. If you do not have it:Client SDKs
Web (React, Next.js, Vite, vanilla JS)
@pylonsync/next. See Clients → React and Clients → Next.js.
React Native (iOS + Android)
Swift (iOS, macOS, tvOS, watchOS, Linux)
In yourPackage.swift:
apt-get install libsqlite3-dev for the SQLite-backed offline replica. See Clients → Swift.
Directory conventions
A Pylon app usually looks like this:pylon dev app.ts watches app.ts and functions/, and regenerates pylon.manifest.json and pylon.client.ts on every change.
Environment variables
Dev shortcuts
Dev mode turns on shortcuts that give full control of the app:dev_code/dev_tokenin magic-code, email-verification, phone, and magic-link responsesPOST /api/auth/sessionand/api/auth/upgradefor any user id- the OAuth callback’s
emailparameter in place of a providercode /admin/*and/metricswithout a token (when noPYLON_ADMIN_TOKENis set)- the dev file API and
/_pylon/dev/render
Host header is localhost, *.localhost, 127.x.x.x, [::1], or the Android emulator’s 10.0.2.2, and the Origin header, if sent, is a localhost page. A request from another device, through a tunnel such as ngrok, from a page that re-pointed its own domain at 127.0.0.1, or from another website open in your browser is served as production. A local proxy that rewrites Host to localhost (ngrok --host-header=rewrite, a Vite proxy with changeOrigin, editor port forwarding) makes remote callers look local, so don’t run one on an untrusted network. pylon dev --host 0.0.0.0 lets your phone reach the dev server, and the phone signs in the normal way: email codes print to the pylon dev terminal when no email provider is set.
See the CLI reference for the full list.