This content originally appeared on DEV Community and was authored by Shayam Murali
Brahma-JS: Ultra-Low Latency JS Runtime Powered by Rust
Rust is amazing for speed, safety, and stability—but let’s be real: most JS/TS devs don’t want to wrangle the borrow checker, strict type system, and ownership rules just to build web APIs.
That’s why I built Brahma-JS — an ultra-low latency runtime written in Rust on top of Tokio + Hyper, but plug-and-play with Node, Deno, and Bun.
What it does
- All heavy lifting (
req.body
, headers, query parsing, etc.) runs in Rust. - Works directly inside your existing JS ecosystem (Node, Deno, Bun).
- Fire-and-forget, fully sync-style architecture.
- Lets you write type-safe, memory-safe, blazing-fast HTTP routes with the simplicity of JS.
Example with installation
const { useBrahma, startServer, redirect } = require("brahma-firelight");
useBrahma((req) => {
if (req.path === "/hi") {
return {
headers: { "Content-Type": "application/json" },
status: 200,
body: JSON.stringify({ message: "Hello World from Brahma-JS!" }),
};
}
if (req.path === "/bye") {
return redirect("https://example.com");
}
return {
status: 404,
body: "Route not found",
};
});
const port = process.env.PORT || 3000;
const host = process.env.HOST || "0.0.0.0";
startServer(host, +port).then(() => {
console.log(`🌀 Brahma-JS server running at http://${host}:${port}`);
});
Benchmarks
On a tiny AWS EC2 t2.micro, I hit:
- 33.2k req/s within 10s of load testing
- No proxy, no hacks — just raw Rust (Hyper + Tokio) under the hood Benchmarks August 2025
(That’s significantly faster than Express/Fastify on the same hardware.)
Try it out
Looking for feedback
- Star
the repo if this excites you
- PRs welcome for early testers
- Drop issues with the features you’d want next
Nobody needs to give up their ecosystem anymore. Write JS, run at Rust speed.
This content originally appeared on DEV Community and was authored by Shayam Murali