Go module
A Go module is a versioned collection of related Go packages defined by a go.mod file and managed as a unit for dependency resolution and builds.
Go in Action, Second Edition
A Go module is a versioned collection of Go packages described by a go.mod file and managed as a unit for dependency resolution and builds.
- How it is used
- Organizes packages into named projects and manages dependencies for both small programs and independently evolving application components.
- How deep it goes
- Works through initialization, go.mod entries, dependency commands, and multimodule organization without detailing the dependency-resolution algorithm.
- Examples
- Uses a word-count project and a four-module RSS reader with domain, storage, API, and worker components.
- What you can do after
- Build it from scratch: initialize a module, inspect go.mod, and plan separate modules for components that should evolve independently.
Go in Practice, Second Edition
A Go module is a versioned collection of Go packages described by a go.mod file and its dependency requirements.
- How it is used
- Manages package dependencies as part of the Go toolchain.
- How deep it goes
- Explains the productivity and compile-time rationale, but does not detail go.mod syntax or version-selection internals.
- Examples
- Uses standard-library imports, an external URL import, and `go get ./...`.
- What you can do after
- Operate/configure dependencies with Go's integrated module tooling.
Read how Go in Practice, Second Edition explains go module →
Learn Go with Pocket-Sized Projects
A Go module is a versioned collection of Go packages defined by a go.mod file.
- How it is used
- Starts standalone Go applications, libraries, command-line tools, and HTTP services by establishing their project boundary.
- How deep it goes
- Explains initialization, go.mod creation, naming, and common layouts, but does not detail dependency versioning or module commands beyond setup.
- Examples
- Uses hello-world, bookworms, genericcache, an HTTP service, a maze solver, and a money-conversion CLI.
- What you can do after
- Build it from scratch by initializing a module, creating go.mod, choosing a module path, and organizing application or library files.
Read how Learn Go with Pocket-Sized Projects explains go module →
gRPC Microservices in Go
A Go module is a versioned unit of Go source code and dependency metadata managed as a cohesive module.
- How it is used
- Organizes each microservice and its generated gRPC code for dependency management across service boundaries.
- How deep it goes
- Explains initialization, module paths, version selection, repository tags, and separate test modules, without detailing Go dependency resolution internals.
- Examples
- Uses order, payment, and shipping modules, versioned generated clients, go.mod initialization, and a separate e2e module.
- What you can do after
- Apply it via go mod init and go get to create services, consume generated clients, pin versions, and isolate end-to-end tests.
Related concepts
- go.mod fileconfigured by · A go.mod file is a Go module manifest that declares the module path, Go language version, and required dependencies.
- packagehas part · A package is a programming-language namespace and organizational unit that groups related code and may define import, compilation, or access boundaries.
- go mod initconfigured by · go mod init is a Go command that initializes a module by creating its go.mod file with a specified module path.
- go workspaceused by · A Go workspace is a development configuration that coordinates multiple Go modules for joint development and testing while preserving their independent module definitions.
- go getconfigured by · go get is a Go command that adds or updates module dependencies and their required versions in a module’s dependency metadata.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.



