github.com/asaskevich/govalidator

govalidator

Package govalidator is package of validators and sanitizers for strings, structs and collections.

92

Decision Signals

Health score 92/100, confidence 100/100.

Excellent
Maintenance 83
Adoption 100
Security 92
Maturity 93
Developer DX 97
Confidence 100

Install

go get github.com/asaskevich/govalidator

Package Data

updated May 28, 2026
Latest versionv0.0.0-20230301143203-a9d515a09cc2
Imported by4.7K packages
Stars6.2K
Forks565
Last activity9 days ago
Latest releasev11.0.1 (5 years ago)
LicenseMIT
Known vuln records0

API Surface

250 symbols
SymbolKindSynopsis
ConditionIterator Type type ConditionIterator func(interface{}, int) bool
CustomTypeValidator Type type CustomTypeValidator func(i interface{}, o interface{}) bool
Error Type type Error struct{ ... }
Error.CustomErrorMessageExists Field CustomErrorMessageExists bool
Error.Err Field Err error
Error.Error Method func (e Error) Error() string
Error.Name Field Name string
Error.Path Field Path []string
Error.Validator Field Validator string
Errors Type type Errors []error
Errors.Error Method func (es Errors) Error() string
Errors.Errors Method func (es Errors) Errors() []error

Similar Packages

Go Validation Libraries

#1 Validator

Package validator implements value validations for structs and individual fields based on tags.

Go Validation Libraries 20.0K stars 24.1K imported-by 100% confidence
96

#2 validate

Package validate is a generic go data validate, filtering library.

Go Validation Libraries 1.1K stars 0 imported-by 80% confidence
84

#3 go-proto-validators

Generate message validators from .proto annotations.

Go Validation Libraries 1.1K stars 1.0K imported-by 95% confidence
73

#4 v4

Package validation provides configurable and extensible rules for validating data of various types.

Go Validation Libraries 4.1K stars 2.3K imported-by 95% confidence
73

#5 validation

Package validation provides methods for validating parameter value using reflection.

Go Validation Libraries 0 stars 77.0K imported-by 75% confidence
69