v1.0.5 is live — Star us on GitHub

Replace Your Frontend
Stack with NexGo

Everything you need — routing, rendering, and APIs — packed into a lightweight, high-performance engine. No setup. Just build fast.

$ go install github.com/salmanfaris22/nexgo/cmd/nexgo@v1.0.5
1. Install 2. nexgo create my-app 3. nexgo dev
0
Requests / second
0
Binary size
0
Runtime dependencies
0
Lines of source code
Core Features

Everything you need,
nothing you don't

NexGo ships with all the primitives to build production web apps — without the complexity.

📁

File-Based Routing

Drop HTML files in pages/ and routes are created automatically. Dynamic segments with [param] syntax, catch-all routes, and nested layouts.

Server-Side Rendering

Full SSR, SSG, and SPA modes. Data loaders run server-side before rendering — just like Next.js getServerSideProps.

🔥

Hot Reload

Save a file and your browser refreshes instantly. Powered by SSE-based HMR — no WebSockets, no complex setup.

🔌

API Routes

Add .go files in pages/api/ to create REST endpoints with method routing, JSON helpers, pagination, and more.

📦

Single Binary Deploy

Compile to a ~10MB binary. Deploy anywhere Go runs. Just copy the binary + your pages — no Node.js, no npm, no runtime.

🛠

DevTools Panel

Built-in debug panel at /_nexgo/devtools. Live request logs, route inspector, performance metrics, and config viewer.

Simple by Design

Next.js DX,
Go Performance

NexGo brings the familiar Next.js developer experience to Go. File-based routing, data loaders, and layouts — all powered by Go's blazing-fast runtime.

Zero runtime dependencies — stdlib only
Go's html/template engine — XSS safe by default
Compile once, run anywhere — Docker-friendly
Built-in middleware: CORS, Gzip, Security headers
pages/api/posts.go
package api

import (
    "net/http"
    "github.com/salmanfaris22/nexgo/pkg/api"
    "github.com/salmanfaris22/nexgo/pkg/router"
)

func init() {
    router.RegisterAPI("/api/posts", Posts)
}

func Posts(w http.ResponseWriter, r *http.Request) {
    api.Route(w, r, api.Methods{
        "GET": func(w http.ResponseWriter, r *http.Request) {
            page, limit := api.Paginate(r)
            posts := getAllPosts(page, limit)
            api.JSON(w, posts)
        },
        "POST": createPost,
    })
}
pages/blog/[slug].html
<!-- Auto-mapped to /blog/:slug -->

          
Project Structure

Familiar,
Intuitive Layout

my-app/
my-app/
├── main.go               # Entry point
├── nexgo.config.json     # Config
├── go.mod
│
├── pages/               # Routes (auto)
│   ├── index.html        # → /
│   ├── about.html        # → /about
│   ├── blog/
│   │   ├── index.html    # → /blog
│   │   └── [slug].html   # → /blog/:slug
│   └── api/
│       └── hello.go      # → /api/hello
│
├── layouts/
│   └── default.html      # Wraps pages
├── components/           # Partials
└── static/              # Assets → /static/
    ├── css/
    └── js/

CLI Commands

$nexgo create my-app
$nexgo dev
$nexgo build
$nexgo start --port 4000

⚡ PATH tip: After install, run export PATH=$PATH:$(go env GOPATH)/bin to use the nexgo command globally.

Open Source · MIT License

Ready to build something
blazing fast?

Join the community. Star the repo. Build your next project with the simplicity of Next.js and the power of Go.

Creator

Made by Salman Faris

Full-stack developer building cool things with Go and modern web tech.