A module is a collection of related Go packages. Modules are the unit of source code interchange and versioning. The go command has direct support for working with modules, including recording and resolving dependencies on other modules. Modules replace the old GOPATH-based approach to specifying which source files are used in a given build.
The Go Module concept was first published by Russ Cox here: Defining Go Modules.
Module support first appeared in Go 1.11 (in preliminary phase).
The go tool
has built-in and extensive support for modules, documentation can be found at Go tool: Module maintenance and at Modules, module versions, and more. The command go help mod
also provides sufficient details.