Description
100go.co is a free online summary of the mistakes covered in the book 100 Go Mistakes and How to Avoid Them, by Teiva Harsanyi. Each common Go mistake is numbered and grouped by topic, so you can read the summary as a checklist for writing better Go. The sections cover code and project organization, including variable shadowing, unnecessary nested code, misusing init functions, interface pollution, the placement of interfaces, generics, type embedding, the functional options pattern, package misorganization and linters. Data types are covered with octal literals, integer overflow, floating-point numbers, slice length and capacity, nil versus empty slices, and maps. Control structures include range loops, map iteration, break and defer in loops. Strings cover runes, iteration, trim functions and concatenation. Functions and methods cover receiver types, named results and returning a nil receiver. The site also flags entries that no longer apply in newer Go releases, such as mistakes that stopped being relevant from Go 1.22, 1.23 and 1.25. The site is available in English, Simplified Chinese, Japanese and Brazilian Portuguese, and it links to the book's source examples and a newsletter.…
Highlights
- Numbered list of common Go mistakes
- Grouped by topic
- Notes on Go versions where an item no longer applies
- Available in four languages
- Links to source examples
Ratings & Reviews
No ratings yet
Be the first to rate 100 Go Mistakes.
People also visit

golang-patterns
Idiomatic Go patterns, best practices, and conventions for building robust
100 Go Mistakes FAQ
What is 100go.co?
A summary of the mistakes in the book 100 Go Mistakes and How to Avoid Them, presented as a searchable reference.
How is it organized?
By topic, including code organization, data types, control structures, strings, and functions and methods.
Are all the mistakes still relevant?
Not always. The site marks some entries that are no longer relevant from Go 1.22, 1.23 or 1.25.
What languages is it in?
English, Simplified Chinese, Japanese and Brazilian Portuguese.
Where are the examples?
The site links to the example code in the book's GitHub repository.
Where is the source?
The book has a GitHub project, teivah/100-go-mistakes, which holds the example code.



