Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Go
  3. gountries

gountries

MITGov0.1.6

A Go library providing structured ISO-standard country, subdivision, currency, and geographic data with translations and borders.

GitHubGitHub
435 stars72 forks0 contributors

What is gountries?

Gountries is a Go library that provides structured access to ISO-standardized data about countries, their subdivisions, currencies, and geographic coordinates. It solves the problem of needing reliable, up-to-date international data for applications dealing with locations, borders, or multi-regional content by offering easy querying and embedded data.

Target Audience

Go developers building applications that require international data, such as geographic services, multi-language platforms, or systems handling country-specific regulations and currencies.

Value Proposition

Developers choose Gountries for its comprehensive ISO-standard data, simple API, and embedded data approach, which eliminates external dependencies and ensures consistency across deployments.

Overview

Gountries provides: Countries (ISO-3166-1), Country Subdivisions(ISO-3166-2), Currencies (ISO 4217), Geo Coordinates(ISO-6709) as well as translations, country borders and other stuff exposed as struct data.

Use Cases

Best For

  • Building location-based services that need country and subdivision data
  • Developing multi-regional applications requiring currency and translation support
  • Calculating distances between countries for logistics or mapping tools
  • Querying bordering countries for geographic analysis
  • Embedding standardized country data without external API calls
  • Creating applications with administrative subdivision lookups

Not Ideal For

  • Projects requiring real-time or frequently updated country data, as Gountries uses embedded YAML files that must be manually regenerated for updates.
  • Applications needing detailed geographic shapes or GeoJSON data, since it's listed as a todo and not yet implemented in the README.
  • High-performance geospatial computations with large datasets, as it relies on basic Haversine and Pythagorean methods which may not scale efficiently.
  • Systems that depend on non-ISO standards or custom data sets, because Gountries is strictly based on ISO specifications without extensibility hooks.

Pros & Cons

Pros

ISO Standardized Data

Provides structured access to ISO-3166-1 countries, ISO-3166-2 subdivisions, and ISO 4217 currencies, ensuring data reliability as shown in the README examples with Sweden and Germany.

Embedded Data Dependencies

Uses go-bindata to embed YAML files, eliminating external dependencies and simplifying deployment, as mentioned in the 'Using packed data' section.

Comprehensive Translations

Includes country names and official names in multiple languages, demonstrated in the basic example with German translations for Sweden.

Easy Querying API

Offers intuitive functions like FindCountryByName and FindCountries for flexible data retrieval, as illustrated in the advanced examples with border queries.

Cons

Work in Progress Limitations

The README explicitly states it's a work in progress with missing features like GeoJSON information, which limits its use for advanced geographic applications.

Data Update Complexity

Updating data requires running go-bindata to regenerate embedded files, adding a manual step that complicates automation and real-time data synchronization.

Limited Geographic Detail

Focuses on country-level data without city or detailed shape support, as evidenced by the todo list and distance calculation examples only using country coordinates.

Frequently Asked Questions

Quick Stats

Stars435
Forks72
Contributors0
Open Issues17
Last commit3 months ago
CreatedSince 2016

Tags

#translations#geographic-data#go-library#country-data#distance-calculation#iso-standards

Built With

Y
YAML
G
Go

Included in

Go169.1k
Auto-fetched 1 day ago

Related Projects

gopsutilgopsutil

psutil for golang

Stars11,898
Forks1,683
Last commit1 day ago
gatusgatus

Automated developer-oriented status page with alerting and incident support

Stars11,870
Forks804
Last commit4 days ago
gofakeitgofakeit

Random fake data generator written in go

Stars5,380
Forks298
Last commit1 day ago
puregopurego

A library for calling C functions from Go without Cgo

Stars3,796
Forks122
Last commit1 day ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub