explaingit

hoisie/web

Analysis updated 2026-07-03

3,683GoAudience · developerComplexity · 2/5Setup · easy

TLDR

A minimal Go web framework that handles regex-based URL routing, secure cookies, and static file serving in about seven lines of code, inspired by Sinatra and web.py.

Mindmap

mindmap
  root((web.go))
    What It Does
      HTTP routing
      Go web framework
      Minimal footprint
    Features
      Regex URL routing
      Secure cookies
      Static file serving
      FastCGI and SCGI
    Tech Stack
      Go
    Use Cases
      Lightweight APIs
      Simple web services
      Go prototypes
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Build a lightweight Go web service with regex-based URL routing without importing a heavy framework.

USE CASE 2

Manage user sessions with secure cookies in a Go web application.

USE CASE 3

Serve static files alongside your Go web routes using the built-in static file handler.

USE CASE 4

Deploy a Go web app over FastCGI or SCGI as an alternative to the standard HTTP server.

What is it built with?

Go

How does it compare?

hoisie/webfortio/fortioloov/lensm
Stars3,6833,6913,691
LanguageGoGoGo
Setup difficultyeasyeasyeasy
Complexity2/52/52/5
Audiencedeveloperops devopsdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 5min

Requires a working Go environment. Install with go get github.com/hoisie/web.

In plain English

web.go is a lightweight framework for building web applications in the Go programming language. A web framework provides the basic plumbing that most web services need, such as routing incoming requests to the right handler function, reading URL parameters, and sending responses. web.go aims to be minimal and not impose any particular project structure on the developer. The framework matches incoming URL paths using regular expressions and calls the corresponding Go function. It handles secure cookies for managing user sessions, supports static file serving, and works with two alternative server protocols called FastCGI and SCGI in addition to the standard HTTP server. Because Go compiles to native machine code rather than running on a virtual machine, applications built with web.go execute quickly. The README compares it to Sinatra (a Ruby framework) and web.py (a Python framework), positioning it as a similar thin layer for developers who want routing and helpers without a larger, more opinionated system. Installation requires a working Go environment. Adding the library to a project is a single command: go get github.com/hoisie/web. A minimal example in the README shows a complete working web server in about seven lines of code: import the package, define a handler function that returns a string, register a route with web.Get, and call web.Run with a host and port. Handler functions can also accept a context object that carries request data including URL query parameters. API documentation is hosted separately. The project was written by Michael Hoisie and is one of the early Go web frameworks, predating more widely adopted options that came later in the Go ecosystem.

Copy-paste prompts

Prompt 1
Help me build a simple JSON REST API in Go using the web.go framework with route parameters and proper response headers.
Prompt 2
Show me how to use web.go's secure cookie support to store and read a user session token across requests.
Prompt 3
I want to serve a folder of static files (CSS, JS, images) from my web.go app, show me how to add a static file route.
Prompt 4
Help me write a web.go handler that reads URL query parameters from the context object and returns a formatted response.
Prompt 5
Walk me through configuring my web.go application to run in FastCGI mode behind an Nginx proxy.

Frequently asked questions

What is web?

A minimal Go web framework that handles regex-based URL routing, secure cookies, and static file serving in about seven lines of code, inspired by Sinatra and web.py.

What language is web written in?

Mainly Go. The stack also includes Go.

How hard is web to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is web for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Scan in gitsafehub Deploy in gitdeployhub hoisie on gitmyhub

Verify against the repo before relying on details.