PHPackages                             wizory/iso3166 - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. wizory/iso3166

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

wizory/iso3166
==============

ISO 3166-1 PHP Library w/ Extensions

2.1.2(3y ago)073MITPHPPHP ^5.6 || ^7.0 || ^8.0 || ^9.0

Since Jun 30Pushed 3y ago1 watchersCompare

[ Source](https://github.com/wizory/iso3166)[ Packagist](https://packagist.org/packages/wizory/iso3166)[ Docs](https://github.com/wizory/iso3166)[ RSS](/packages/wizory-iso3166/feed)WikiDiscussions master Synced yesterday

READMEChangelog (1)Dependencies (2)Versions (9)Used By (0)

wizory/iso3166
==============

[](#wizoryiso3166)

A PHP library providing ISO 3166-1 and related data.

What is ISO 3166-1
------------------

[](#what-is-iso-3166-1)

> ISO 3166-1 is part of the ISO 3166 standard published by the International Organization for Standardization (ISO), and defines codes for the names of countries, dependent territories, and special areas of geographical interest. The official name of the standard is Codes for the representation of names of countries and their subdivisions – Part 1: Country codes. It defines three sets of country codes:
>
> - ISO 3166-1 alpha-2 – two-letter country codes which are the most widely used of the three, and used most prominently for the Internet's country code top-level domains (with a few exceptions).
> - ISO 3166-1 alpha-3 – three-letter country codes which allow a better visual association between the codes and the country names than the alpha-2 codes.
> - ISO 3166-1 numeric – three-digit country codes which are identical to those developed and maintained by the United Nations Statistics Division, with the advantage of script (writing system) independence, and hence useful for people or systems using non-Latin scripts.
>
> *-- [Wikipedia](http://en.wikipedia.org/wiki/ISO_3166-1)*

Installing
----------

[](#installing)

```
$ composer require wizory/iso3166
```

Using
-----

[](#using)

Quick guide:

```
$data = (new League\ISO3166\ISO3166)->alpha2($alpha2);
$data = (new League\ISO3166\ISO3166)->alpha3($alpha3);
$data = (new League\ISO3166\ISO3166)->numeric($numeric);
```

Data sample:

```
[
    'name' => 'United States of America',
    'short_name' => 'United States',
    'alpha2' => 'US',
    'alpha3' => 'USA',
    'numeric' => '840',
    'currency' => [
        'USD',
    ],
]
```

Contributing
------------

[](#contributing)

Feel free to submit a pull request or create an issue.

License
-------

[](#license)

wizory/iso3166 is licensed under the MIT license.

Source(s)
---------

[](#sources)

- [ISO 3166-1](http://en.wikipedia.org/wiki/ISO_3166-1) by [Wikipedia](http://www.wikipedia.org) licensed under [CC BY-SA 3.0 Unported License](http://en.wikipedia.org/wiki/Wikipedia:Text_of_Creative_Commons_Attribution-ShareAlike_3.0_Unported_License)
- [www.iso.org](http://www.iso.org)

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity86

Battle-tested with a long release history

 Bus Factor1

Top contributor holds 75% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~333 days

Recently: every ~527 days

Total

8

Last Release

1319d ago

Major Versions

1.x-dev → 2.0.02017-05-11

PHP version history (3 changes)1.0.0PHP ^5.5 || ^7.0

2.0.0PHP ^5.6 || ^7.0

2.1.2PHP ^5.6 || ^7.0 || ^8.0 || ^9.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/587350?v=4)[Josh Guice](/maintainers/jguice)[@jguice](https://github.com/jguice)

---

Top Contributors

[![alcohol](https://avatars.githubusercontent.com/u/21414?v=4)](https://github.com/alcohol "alcohol (45 commits)")[![jguice](https://avatars.githubusercontent.com/u/587350?v=4)](https://github.com/jguice "jguice (9 commits)")[![localheinz](https://avatars.githubusercontent.com/u/605483?v=4)](https://github.com/localheinz "localheinz (2 commits)")[![duncan3dc](https://avatars.githubusercontent.com/u/546811?v=4)](https://github.com/duncan3dc "duncan3dc (1 commits)")[![drcreazy](https://avatars.githubusercontent.com/u/3186282?v=4)](https://github.com/drcreazy "drcreazy (1 commits)")[![nikolaposa](https://avatars.githubusercontent.com/u/6012807?v=4)](https://github.com/nikolaposa "nikolaposa (1 commits)")[![npispas](https://avatars.githubusercontent.com/u/22989333?v=4)](https://github.com/npispas "npispas (1 commits)")

---

Tags

librarycountriesISO 3166iso31663166-1

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/wizory-iso3166/health.svg)

```
[![Health](https://phpackages.com/badges/wizory-iso3166/health.svg)](https://phpackages.com/packages/wizory-iso3166)
```

###  Alternatives

[league/iso3166

ISO 3166-1 PHP Library

69937.6M136](/packages/league-iso3166)[payum/iso4217

ISO 4217 PHP Library

16112.5M5](/packages/payum-iso4217)[alcohol/iso4217

ISO 4217 PHP Library

15010.9M33](/packages/alcohol-iso4217)[dekor/php-array-table

PHP Library for printing associative arrays as text table (similar to mysql terminal console)

297.4M2](/packages/dekor-php-array-table)[juanparati/iso-codes

A PHP library that provides ISO codes, currencies, languages, timezones and additional geopolitical information

17164.7k](/packages/juanparati-iso-codes)[thalidzhokov/country-codes

CountryCodes PHP Class to get array of countries with ISO 3166-1 alpha-2, ISO 3166-1 alpha-3, ISO 3166-1 numeric and ISD codes it can provide following information related to country

12114.8k](/packages/thalidzhokov-country-codes)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
