Pack Full‑Stack Web Apps into a Single Binary with EXE Tool
Introduction
When building a modern web application, developers often juggle multiple runtimes, build tools, and deployment platforms. If you need to keep server‑side features such as SSR, API endpoints, or authentication, bundling the whole app into a lightweight executable can simplify distribution.
EXE – short for Executable, is a free, MIT‑licensed tool that turns any full‑stack framework (SvelteKit, Nuxt, TanStack) into a single binary with zero runtime dependencies. By leveraging Bun for the build phase, EXE preserves your framework’s native server capabilities while delivering an instant, cross‑platform binary.
Why EXE? * Simplicity – No Docker or Node installation needed at runtime. * Safety – Runs locally, keeping user data private. * Portability – Binary runs on Windows, macOS, Linux, and even embedded devices. * Speed – One command runs the app; no container orchestration.
Key Features
| Feature | Detail |
|---|---|
| Zero Runtime Dependences | Your app ships as a single static binary—no extra files or dependencies on the host. |
| Full‑Stack Preservation | Keeps SSR, API routes, server middleware, and authentication intact. |
| Cross‑Platform | Generates binaries for Windows, Linux, macOS, and ARM architectures. |
| Docker Companion | If you compile for linux-x64, EXE auto‑generates a Dockerfile for quick self‑hosting via Fly.io or any container runtime. |
| CLI & Adapter Plugins | Separate adapters for SvelteKit (@jesterkit/exe-sveltekit) and experimental support for Nuxt/TanStack. |
| Open‑Source & Extensible | GitHub‑hosted, contributions welcome; plugins can be written for other frameworks. |
Getting Started
Below is a sample setup for SvelteKit. Using Nuxt or TanStack follows a similar flow.
# 1️⃣ Install the adapter
npm install @jesterkit/exe-sveltekit
Add it to svelte.config.js:
// svelte.config.js
import adapter from '@jesterkit/exe-sveltekit';
export default {
kit: {
adapter: adapter({
binaryName: 'my-app',
}),
},
};
Run the build pipeline:
npm run build
# The executable is now in ./dist/my-app
./dist/my-app
Your app will launch at http://localhost:3000 and behave exactly like the standard SvelteKit production build, but now as a single binary.
Advanced Settings
| Option | Usage |
|---|---|
--target |
linux-x64, win32-x64, darwin-arm64, etc. |
--output |
Custom location for the compiled binary. |
--docker |
Forces Dockerfile generation even without linux-x64. |
Example – Build a Linux binary and generate a Dockerfile:
npm run build -- --target=linux-x64 --docker
Deployment via Fly.io
If you target linux-x64, the fly launch helper ships a ready‑to‑use Fly.io configuration. Simply run:
fly launch
Fly handles hosting, domain assignment, and zero‑downtime reloads.
Use Cases
| Scenario | Benefit |
|---|---|
| SaaS demo storefront | Let customers spin up a copy locally for quick trials. |
| Privacy‑centric apps | Store data on the user's device without exposing it to a remote server. |
| Self‑hosted tools | Distribute a single binary for administrators to install on internal servers. |
| Rapid prototyping | Avoid docker build times and instantly test feature changes. |
Community & Extension
The EXE ecosystem is growing. If you use a framework not listed above, feel free to open an issue or contribute an adapter. Because the core is written in Rust and uses bun for bundling, it scales well and can incorporate new features such as:
- Auto‑updating binaries
- Native plugin support
- Platform‑specific bundlers (WebAssembly, ARM64, etc.)
Contributing
- Fork the repo.
- Make your changes locally.
- Submit a PR describing the problem and solution.
We appreciate small, focused PRs. The project is MIT‑licensed, so you can even use the binaries in commercial software.
License
EXE is licensed under the MIT license – feel free to adapt and ship it as part of your product.
Summary
EXE bridges the gap between the rich ecosystem of full‑stack frameworks and the simplicity of a single binary. It removes the need for Docker containers, Node runtimes, or complex deployment scripts while keeping all server‑side features intact. Whether you’re building a demo, a self‑hosted SaaS, or a privacy‑focused tool, EXE gives you a zero‑friction way to ship your web app to any platform.
Happy packaging!