Automated ranking

Best Go Configuration Libraries

Compare go configuration libraries by maintenance, adoption, security, release activity, and Go ecosystem usage. Top packages in this group include v2, env, Koanf.

Best overall

v2

Highest combined package health score.

96
Best maintained

v2

Strongest maintenance signal in this category.

95
Most adopted

v2

Highest adoption signal from stars, forks, and imported-by data.

100

Ranked Packages

13 packages

#1 v2

Package config is a go config management implement.

Go Configuration Libraries 583 stars 215 imported-by 95% confidence
96

#2 env

A simple, zero-dependencies library to parse environment variables into structs

Go Configuration Libraries 6.2K stars 1.4K imported-by 100% confidence
95

#3 Koanf

Simple, extremely lightweight, extensible, configuration management library for Go. Supports JSON, TOML, YAML, env, command line, file, S3 etc. Alternative to viper.

Go Configuration Libraries 4.1K stars 540 imported-by 100% confidence
95

#4 xdg

Package xdg provides an implementation of the XDG Base Directory Specification.

Go Configuration Libraries 1.0K stars 1.2K imported-by 100% confidence
93

#5 Viper

Go configuration with fangs.

Go Configuration Libraries 30.3K stars 0 imported-by 80% confidence
85

#6 cue

The home of the CUE language! Validate and define text-based and dynamic configuration

Go Configuration Libraries 6.1K stars 0 imported-by 40% confidence
83

#7 configor

Golang Configuration tool that support YAML, JSON, TOML, Shell Environment

Go Configuration Libraries 1.8K stars 870 imported-by 95% confidence
74

#8 agent-sdk-go

Go SDK for building durable AI agents on Temporal with support for tools, MCP, human approvals, and sub-agent delegation.

Go Configuration Libraries 0 stars 0 imported-by 60% confidence
58

#9 argus

File watching and configuration management with MPSC ring buffer, adaptive batching strategies, and universal format parsing (JSON, YAML, TOML, INI, HCL, Properties).

Go Configuration Libraries 0 stars 0 imported-by 35% confidence
48

#10 Kono

lightweight extendable API Gateway in Go - parallel fan-out, flexible aggregation, and zero configuration magic.

Go Configuration Libraries 0 stars 0 imported-by 25% confidence
44

#11 crab-config-files-templating

Dynamic configuration file templating tool for kubernetes manifest or general configuration files.

Go Configuration Libraries 0 stars 0 imported-by 80% confidence
41

#12 ini

Package ini provides INI file read and write functionality in Go.

Go Configuration Libraries 0 stars 0 imported-by 80% confidence
41

#13 go-config

Yaml Config Loader

Go Configuration Libraries 0 stars 0 imported-by 55% confidence
33

Comparison Matrix

score dimensions
Package Health Maintenance Adoption Security Imported by
v2 96 95 100 92 215
env 95 95 100 92 1.4K
Koanf 95 95 100 92 540
xdg 93 88 100 92 1.2K
Viper 85 80 100 70 0
cue 83 95 85 70 0
configor 74 27 100 92 870
agent-sdk-go 58 90 7 70 0
argus 48 48 7 92 0
Kono 44 48 7 70 0
crab-config-files-templating 41 15 7 92 0
ini 41 15 7 92 0
go-config 33 15 5 70 0

Related Comparisons

Go Configuration Libraries

env vs Koanf

Compare health, maintenance, adoption, security, and release signals.

95

env vs xdg

Compare health, maintenance, adoption, security, and release signals.

95

Koanf vs xdg

Compare health, maintenance, adoption, security, and release signals.

95

env vs configor

Compare health, maintenance, adoption, security, and release signals.

95

env vs v2

Compare health, maintenance, adoption, security, and release signals.

96

Koanf vs v2

Compare health, maintenance, adoption, security, and release signals.

96

Koanf vs configor

Compare health, maintenance, adoption, security, and release signals.

95

xdg vs configor

Compare health, maintenance, adoption, security, and release signals.

93