How To Go is a hands-on learning resource for the Go programming language. Inspired by Go By Example, this repository provides concise, runnable Go examples that teach real concepts through real code.
Purpose: remove friction from learning. Every example must be runnable, simple, and focused.
- Website (WIP): https://howtogo.dev
- Examples Folder:
/examples - Documentation:
/docs - Issues / Feature Requests: https://github.com//how-to-go/issues
Modern developers learn by doing. Books, docs, and tutorials are useful but rarely designed for the fastest path to operational fluency. How To Go solves that by:
- Teaching concepts through runnable code
- Eliminating noise and academic filler
- Providing real-world examples and patterns
- Increasing depth over time with iteration
How To Go is not a rewrite of the Go spec or standard documentation; it is a bridge between theory and practice.
- Developers new to Go
- Experienced programmers switching languages
- Cloud & systems engineers expanding skillsets
- People who want reference examples, fast
-
Minimal Complexity
Examples are small, targeted, and easy to run. -
Direct Utility
Every example must demonstrate value. -
Progressive Depth
Beginners start simple. Experts dig deeper. -
Real Code Only
No pseudocode. No placeholders. No theory without proof.
Actively developed. New examples added continuously.
Goal: 300+ runnable examples across all major topics.
templ generate --watch --proxy="http://localhost:8080" --cmd="go run ."
go run .Starts the server on localhost:8080
Verify Go Setup
go version
go env
go work (workspace tool)
The official howtogo.dev site is under development but available at:
https://howtogo.dev
HowtoGo.dev uses the following technologies:
- Go (Golang)
- HTML/CSS/JavaScript
- Templ (for static site generation)
- Caddy HTTPS server
- GitHub Pages (for hosting)
Caddy is written in Go and uses:
- Non-blocking I/O
- Efficient connection reuse
- HTTP/2 and HTTP/3 (QUIC) support
- Automatic HTTPS with Let's Encrypt
- Revserse proxy capabilities
- Secure by default configurations
Caddy is ideal for serving Go applications due to its performance, security features, and ease of use. Because howtogo.dev doesn't contain hundreds of pages, Caddy's lightweight footprint and fast startup times make it a perfect fit for hosting the site efficiently.
Contributions welcome! Please read the CONTRIBUTING.md guide for details on how to contribute.
Created by Keith. Dedicated to learning, programming, and cloud-native systems 😄.
MIT

