Serve files at native speed from one binary.
Servexy is a zero-config HTTP file server built with Go. Install once, serve any folder, ship your SPA — all from a single native binary that boots in milliseconds.
npm install -g servexy A file server that just works.
One binary. Zero config. Built for the way modern web developers actually ship.
Lightning Fast
Native Go binary. Zero JS overhead. Cold start in under 10ms.
Zero Configuration
One command serves any directory. No config files, no setup wizards.
SPA History Fallback
Pass -s and missing HTML routes serve index.html — built for Vue, React, and Svelte.
Network Access
Bind to your LAN with -n. Share files across devices instantly.
Prebuilt Binaries
Install-script free. Ships prebuilt binaries — install in milliseconds.
Cross-Platform
Windows, macOS, Linux. Native x64 and ARM64 support on every platform.
Install your way.
Ship in seconds.
bun install -g servexy bunx servexy -p 8080 npm install -g servexy npx servexy -p 8080 yarn global add servexy yarn dlx servexy -p 8080 pnpm add -g servexy pnpm dlx servexy -p 8080 Common recipes
Serve current dir
servexy Default port 8080
Custom port
servexy -p 3000 Any port from 1–65535
Specific directory
servexy -d ./public Point at any folder
Network mode
servexy -n Bind to 0.0.0.0 (LAN)
SPA fallback
servexy -d ./dist -s Vue / React / Svelte history routing
Build SPA + serve
vite build && servexy -d ./dist -s One-liner for production preview
CLI Flags
-
-p, -portPort to serve on (default: 8080) -
-d, -dirDirectory to serve (default: current) -
-n, -networkBind on all interfaces (LAN access) -
-s, -spaServe index.html for missing HTML routes v1.1 -
-h, -helpShow the help message