NexGo v2.2.1
SEO Killer Mode — the most SEO-complete Go framework. Auto sitemap, robots.txt, 10 JSON-LD schema types, OpenGraph, Twitter Cards, RSS feeds, Core Web Vitals, hreflang, breadcrumbs, SEO audit — all built-in with zero config. Plus 200k+ req/sec performance and zero-JS Islands.
SEO Killer Mode + Performance + Islands + 30 Features
The most SEO-complete Go framework, plus 200k+ req/sec performance, zero-JS Islands, and all production features.
SEO Killer Mode
HEADLINEThe most SEO-complete Go framework. Auto sitemap.xml & robots.txt, canonical URLs, 10 JSON-LD schema types, OpenGraph + Twitter Cards, article OG tags, RSS feeds, hreflang, breadcrumbs, Core Web Vitals tracking, SEO audit, redirects, HSTS, and 22+ template functions โ all zero config.
High-Performance Mode
HEADLINEPush throughput from 50k to 200,000+ req/sec on multi-core machines. Cluster mode spawns one HTTP worker per CPU core. Async logging, response caching, atomic template reads, and route match caching โ all configurable.
Islands Architecture
HEADLINE
Pages are static HTML by default. Only interactive components ("islands") ship JavaScript, with fine-grained control over when they hydrate. Choose from 5 strategies: client:load, client:visible, client:idle, client:media, and client:none.
Environment Variables
Load .env files, validate required vars, set defaults, and access typed values. Supports multiple environments out of the box.
Session Management
Cookie-backed sessions with configurable stores. Supports Flash messages, expiry, and secure defaults for production.
JWT Authentication
Sign, verify, and refresh JSON Web Tokens. Includes middleware for protected routes and role-based access control helpers.
CSRF Protection
Automatic token generation and validation middleware. Works with forms and AJAX requests, integrates with sessions.
Rate Limiting
IP-based and key-based rate limiting with sliding window algorithm. Returns standard rate-limit headers automatically.
i18n & RTL
Internationalization with locale files, pluralization rules, and automatic RTL layout detection. Template helpers included.
Image Optimization
Resize, crop, and convert images on the fly. WebP output, lazy-load attributes, and responsive srcset generation.
WebSocket Support
Full-duplex WebSocket connections with rooms, broadcast, and per-client messaging. Built on gorilla/websocket under the hood.
Health Checks
Liveness and readiness endpoints for Kubernetes and load balancers. Register custom checkers for DB, Redis, and more.
Structured Logging
JSON and text loggers with levels, context fields, and request-scoped tracing. Drop-in replacement for the standard library.
Prometheus Metrics
Expose request duration, status codes, and custom counters at /metrics. Grafana-ready with zero configuration.
Database & SQL Builder
Fluent query builder for Postgres, MySQL, and SQLite. Connection pooling, transactions, and named parameters built in.
Migration System
Version-controlled schema migrations with up/down support. CLI commands to create, run, rollback, and check migration status.
Plugin System
Register, load, and compose plugins with lifecycle hooks. Build reusable modules that integrate cleanly into any NexGo app.
Server Actions
Define server-side functions that can be called directly from templates. Form handling, validation, and redirect helpers included.
Error Pages & Boundaries
Custom error pages for 404, 500, and any status code. Error boundaries catch panics and render fallback templates gracefully.
Testing Utilities
Test helpers for routes, middleware, and templates. Includes a mock server, request builders, and assertion helpers.
Per-Route Middleware & CSP
Attach middleware to individual routes or groups. Content Security Policy headers with nonce generation for inline scripts.
Deployment Adapters
One-command deploy to 8 platforms: Docker, Fly.io, Railway, Render, Vercel, AWS Lambda, GCP Cloud Run, and DigitalOcean.
Redis Cache
Redis-backed caching with TTL, tags, and invalidation. Includes middleware for full-page caching and fragment caching helpers.
Asset Pipeline
Bundle, minify, and fingerprint CSS and JS assets. Automatic cache-busting URLs and source map support for development.
ORM Layer
Lightweight ORM with model definitions, relationships (has-one, has-many, belongs-to), eager loading, and soft deletes.
Cluster Mode
Run multiple NexGo instances with shared state. Sticky sessions, distributed locks, and leader election for zero-downtime deploys.
Islands Architecture
Pages are static HTML by default — zero JavaScript. Only interactive components ("islands") ship JS to the browser, with fine-grained control over when they hydrate.
<!-- Static HTML โ 0 KB JavaScript --> <h1>Dashboard</h1> <div class="stats">Revenue: $</div> <!-- Loads immediately --> {{ island "search" (props "endpoint" "/api/search") "client:load" }} <!-- Loads when scrolled into view --> {{ island "chart" (props "data" .Props.chartData) "client:visible" }} <!-- Loads when browser is idle --> {{ island "notifications" (props "count" .Props.unread) "client:idle" }} <!-- Only loads on mobile --> {{ island "mobile-filters" nil "client:media=(max-width:768px)" }} <!-- SSR only โ zero JS ever --> {{ island "activity-feed" (props "events" .Props.events) "client:none" }}
All Packages at a Glance
| Package | Feature | Key Functions |
|---|---|---|
pkg/islands |
Islands Architecture | NewRegistry(), Scan(), Render(), GetJS(), RuntimeJS() |
pkg/api |
State, HTMX, Cache, JSON | SetState(), IsHTMX(), HTMXHTML(), Cache(), JSON() |
pkg/seo |
Meta, Sitemap, Robots | DefaultMeta(), RenderSitemap(), RobotsTxt(), JSONLD() |
pkg/stream |
Streaming SSR, SSE | StreamHTML(), NewSSE(), Send(), WriteString() |
pkg/isr |
Incremental Regeneration | New(), Serve(), Revalidate(), Purge() |
pkg/worker |
Worker Pools | New(), Run(), Map(), MapErr(), ForEach() |
pkg/renderer |
Template Caching | LoadAll(), LoadParallel(), CacheInfo(), NewParallelLoader() |
pkg/env |
Environment Variables | Load(), Get(), MustGet(), GetInt(), GetBool() |
pkg/session |
Session Management | NewCookieStore(), Get(), Set(), Flash(), Destroy() |
pkg/auth |
JWT Authentication | Sign(), Verify(), Refresh(), RequireJWT(), RequireRole() |
pkg/csrf |
CSRF Protection | Generate(), Validate(), Middleware(), TemplateField() |
pkg/ratelimit |
Rate Limiting | New(), Allow(), Middleware(), ByIP(), ByKey() |
pkg/i18n |
i18n & RTL | Load(), T(), Plural(), SetLocale(), IsRTL() |
pkg/image |
Image Optimization | Resize(), Crop(), ToWebP(), Srcset(), LazyAttr() |
pkg/websocket |
WebSocket Support | Upgrade(), OnMessage(), Broadcast(), JoinRoom(), Send() |
pkg/health |
Health Checks | NewChecker(), AddCheck(), LiveHandler(), ReadyHandler() |
pkg/logger |
Structured Logging | New(), Info(), Error(), WithFields(), WithTraceID() |
pkg/metrics |
Prometheus Metrics | Handler(), Counter(), Histogram(), Middleware() |
pkg/db |
Database & SQL Builder | Connect(), Select(), Insert(), Where(), Tx() |
pkg/migrate |
Migration System | Create(), Up(), Down(), Status(), Rollback() |
pkg/plugin |
Plugin System | Register(), Load(), OnInit(), OnShutdown(), List() |
pkg/actions |
Server Actions | Handle(), Validate(), Redirect(), BindForm(), Errors() |
pkg/errorpage |
Error Pages & Boundaries | Register(), Render(), Boundary(), Fallback() |
pkg/testing |
Testing Utilities | NewServer(), Request(), AssertStatus(), AssertBody() |
pkg/middleware |
Per-Route Middleware & CSP | Use(), Group(), CSP(), Nonce(), Chain() |
pkg/deploy |
Deployment Adapters | Docker(), Fly(), Railway(), Vercel(), Lambda() |
pkg/cache |
Redis Cache | NewRedis(), Get(), Set(), Invalidate(), TaggedCache() |
pkg/asset |
Asset Pipeline | Bundle(), Minify(), Fingerprint(), URL(), SourceMap() |
pkg/orm |
ORM Layer | Model(), HasMany(), BelongsTo(), Eager(), SoftDelete() |
pkg/cluster |
Cluster Mode | Join(), Sticky(), Lock(), Elect(), Broadcast() |
Ready for 200k+ req/sec?
Drop-in upgrade from v2.2.0 — no breaking changes. All optimizations are opt-in or automatic.