Networking with Go, Made Easy
Learn TCP/IP, Sockets, and Concurrent Network Programming in Golang from Scratch — from networking fundamentals and the Go language itself to production APIs and ethical hacking.
No signup. No paywall. ★ open source on GitHub.
Want to support? Buy me a coffee.
Networking, taught the way it should be — then built in Go
This is a free, hands-on book that teaches computer networking and network programming in Go, end to end: how networks actually work, how to write real networking code in Go, and how to use that code to build production-grade APIs and do offensive/defensive security work. It's written for three readers at once — people new to networking, people new to Go, and working developers who already know both and want a deep, practical reference. Theory comes first, in a warm, story-driven voice with real history and analogies; every hands-on example is a complete, runnable Go program, not a fragment.
Why read a 151-chapter book in 2026, when AI can already write a TCP server?
Because someone still has to know whether the code is right — and that someone is going to be you. An AI model produces plausible code fast; it has never watched a server leak connections at 3 a.m., and it has no stake in what happens when it's wrong. The gap between "code that compiles" and "a system that survives contact with the real internet" is exactly what this book closes — and that gap gets more valuable, not less, the more first drafts get written by something that doesn't understand what it built.
AI changes who writes the first draft of the code. It has not changed who is responsible for understanding it.
It makes you better at AI, not obsolete
The people most effective at directing AI tools aren't the ones who know the least — they're the ones who can spot a wrong answer in one glance and push back when a generated solution is subtly broken.
Networking isn't going anywhere
Every model you've ever talked to is itself served over a network, to a datacenter, on protocols invented decades before it existed. Learning this is a prerequisite for building the future, not competition for it.
Built for every level, on purpose
Whether this is your first program ever or your two-hundredth production deploy, this book starts each topic at zero and earns its way up — no assumed background, no skipped steps, no age or experience floor.
Six parts, 151 chapters
From "what is a network?" to shipping a Go API on Google Cloud and building your own honeypot.
Networking Foundations
OSI & TCP/IP models, IP addressing and subnetting, ports, sockets, protocols, firewalls, NAT, and VPNs — theory only, no code, told through real history.
Go From Scratch
A full Go language crash course before the networking code starts, capped by a flagship chapter on goroutines, channels, and concurrency.
Core Go Networking
TCP, UDP, HTTP, JSON, WebSockets, DNS, proxies, chat apps, file transfer, NAT traversal, context, and TLS — theory paired with runnable Go every time.
Advanced & Specialized
gRPC, WebRTC, MQTT/IoT, SDN, NFV, packet inspection, custom protocols, mesh networks, and real-time networking for games and blockchain.
Cybersecurity & Ethical Hacking
Scanning, sniffing, vulnerability assessment, IDS/IPS, SIEM, malware analysis, red team vs blue team, honeypots, and PKI — for authorized, ethical use.
Production APIs & Architecture
REST and gRPC APIs with Gin and Fiber, PostgreSQL and SQLite, Docker and Google Cloud, Clean/Hexagonal Architecture, and Domain-Driven Design.
Available formats
The book is free and always will be. New formats ship as they're ready — this page always points at the latest.
Web Reader Available
Every one of the 151 chapters has its own page and its own URL, with a search command palette and always in sync with the latest edit — no download needed.
Start ReadingPDF Available
Print-ready, built straight from the book's source with go-pretty-pdf. Always the current release.
Download PDFEPUB Available
For e-readers and mobile apps. Built straight from the book's source with go-pretty-pdf, same as the PDF.
Download EPUBOther formats Coming soon
MOBI is planned next. Star the repo to help decide what ships first.
Star the repoFrom your first "go run" to your two-hundredth deploy
No level is left out. This book was written so that someone who has never opened a terminal and someone who already ships production systems can both start reading today and both get something they can't get from a prompt.
- Beginners who want networking concepts, and Go itself, explained clearly from the ground up.
- Developers who already know Go but want a deep, practical reference for networked systems.
- Anyone prepping for interviews, CTFs, or real-world backend and networking jobs.
- Backend engineers who want a real, production-shaped example — architecture, database, Docker, cloud deploy — instead of a toy.
- Security professionals and tinkerers who want offensive/defensive skills backed by working code.
Every chapter and the full table of contents live in the repository README.
Straight answers, growing with every release
This FAQ isn't static. It grows as readers ask better questions and new chapters ship — currently reflecting book version latest.
Why learn this instead of just asking an AI to write the code?
Because someone still has to know whether the generated code is right, and that someone is you. AI is extraordinary at producing plausible code fast, but it has never operated the system it wrote and has no stake in the consequences when it's wrong. Understanding networking and Go doesn't compete with using AI well — it's what makes you effective at directing it: able to spot a wrong answer in one glance and catch the mistake before it ships.
Is this book really free, no catch?
Yes. No email required, no paywall, no ads. The book text is CC BY-NC 4.0 — free to read, share, and adapt for non-commercial use, as long as you credit the author — and the example code is MIT. The full source lives in the GitHub repository and compiles straight into the PDF you can download above.
I've never written a line of code. Is this too advanced for me?
No — it's written for that reader on purpose. Part 1 is pure theory with zero code, a dedicated Go Fundamentals part teaches the language itself before any networking begins, and every later chapter pairs a concept with a complete, runnable program.
Do I need to know Go before starting?
No. The dedicated Go Fundamentals section covers installation through testing, plus a flagship chapter on goroutines and channels, so Part 2 never assumes you already know the language.
Is it only theory, or does it include real code?
Both, deliberately separated: Part 1 is theory-only so the mental model comes first, and starting with Go Fundamentals, every chapter pairs the concept with a complete, runnable Go program — not a fragment.
Does it cover cybersecurity and ethical hacking?
Yes — Part 3 is 32 chapters on scanning, sniffing, vulnerability assessment, IDS/IPS, SIEM, malware analysis, red team vs blue team, honeypots, and PKI, written for authorized, ethical use: your own labs, CTFs, and systems you're allowed to test.
What formats are available, and what's coming next?
The web reader, PDF, and EPUB are all available now and always track the latest release. MOBI is planned next.
Can I contribute, suggest a chapter, or report an error?
Yes — pull requests, issues, and suggestions are welcome for new labs, corrections, clearer explanations, or entirely new chapters. See the contributing guide in the repository for the basics.
Who wrote this, and why should I trust it?
Omar Flores Salazar. The book text is CC BY-NC 4.0 and the example code is MIT, both fully open in the public repository, so every claim, every code sample, and every chapter is there for anyone to read, run, and check.
Missing your question? Open an issue on GitHub — it may show up here next release.
"The best way to learn networking is to build, break, and secure it."