Documentation
Everything you need to build with react-bun-ssr.
Follow a guided path from your first route to production, or jump straight to the part of the framework you need.
Start a new project
bun --version
mkdir task-tracker
cd task-tracker
bunx --package react-bun-ssr rbssr init
bun install
bun run devFind your way
Start with the guide that fits your next step.
Start
- OverviewWhat react-bun-ssr is, where it fits, and what you build first.
- InstallationInstall Bun, scaffold a project, and run the docs-grade defaults locally.
- Quick StartBuild the Task Tracker example from route files to a working SSR app.
Routing
- File-Based RoutingMap Bun-native route files to URLs, params, API routes, and markdown pages.
- Layouts and GroupsCompose shared UI, middleware, and route groups without leaking them into the public URL.
- MiddlewareRun global and nested request pipeline logic before loaders, actions, pages, and API handlers.
Data
- LoadersFetch server data, stream deferred values, and hydrate them back into the client tree.
- ActionsHandle mutations, redirects, validation, and post-submit navigation flows.
- Error HandlingUse TanStack-style caught errors, notFound, boundaries, and route lifecycle hooks.
Rendering
- SSR and HydrationRender full documents on the server while keeping the client tree in sync.
- Streaming and DeferredStream HTML and deferred loader chunks for faster time-to-content.
- Head and MetaDefine titles and metadata per route without losing SSR determinism.
Deployment
- Bun DeploymentShip the framework with Bun-only runtime assumptions and a minimal production surface.
- ConfigurationConfigure headers, bytecode, ports, and other framework deployment settings.
- TroubleshootingDebug build, hydration, bytecode, fly.io, and Bun runtime deployment issues.
Why teams pick it
A complete foundation, kept simple.
Bun-native runtime
No Node adapter layer. The runtime, build, markdown, and server paths stay Bun-first.
File-based routing
Pages, APIs, layouts, groups, and markdown routes live in one coherent route tree.
Loaders, actions, and defer
Data loading, mutation, and progressive streaming are built into the route contract.
Streaming SSR
Full document streaming and deferred payloads work for first load and soft transitions.
Client transitions
Link and useRouter preserve shared layouts while moving across server-rendered pages.
Markdown routes
Author docs as first-class .md route files without hand-written TSX wrappers.
Generated reference
Find the details when you need them.
Start with the curated API overview, then move into the generated package pages when you need exact signatures.
From the blog
Bun 1.3.12 Made SSR Faster, but the react-bun-ssr Gap Remains
A short update on the April 2026 rerun showing Bun 1.3.12 improving both react-bun-ssr and Next.js while the Bun-native SSR gap remains large. Written by gaudiauj on April 15, 2026.