PHPackages                             jinas/iso-3166 - 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. jinas/iso-3166

ActiveLibrary

jinas/iso-3166
==============

Lookup information with ISO 3166-1 alpha-2, ISO 3166-1 alpha-3 and ISO 3166-1 numeric

v1.0(5y ago)14MITPHP

Since May 22Pushed 5y ago1 watchersCompare

[ Source](https://github.com/boring-dragon/iso-3166)[ Packagist](https://packagist.org/packages/jinas/iso-3166)[ RSS](/packages/jinas-iso-3166/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (3)Used By (0)

iso-3166
========

[](#iso-3166)

[![Build Status](https://camo.githubusercontent.com/c059ea9b7dbd282d0ef708da6aec16e64f0a9e24f58a6f88d6b4048a02ad90d4/68747470733a2f2f7472617669732d63692e6f72672f6a696e61733132332f69736f2d333136362e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/jinas123/iso-3166)[![StyleCI](https://camo.githubusercontent.com/9f6b18bb962dcf65918dd2a3daa0052504f6f5169e0738f6c563c99928b9a522/68747470733a2f2f6769746875622e7374796c6563692e696f2f7265706f732f3236363130373235352f736869656c643f6272616e63683d6d6173746572)](https://github.styleci.io/repos/266107255?branch=master)

> Library to lookup information with ISO 3166-1 alpha-2, ISO 3166-1 alpha-3 and ISO 3166-1 numeric

### Installation

[](#installation)

```
composer require jinas/iso-3166
```

### Usage

[](#usage)

Get country by ISO 3166-1 Alpha-2

```
use Jinas\ISO\ISO3166;

$iso = new ISO3166;
var_dump($iso->whereAlpha2('no'));

/* Returns:
  {
    country: 'Norway',
    alpha2: 'NO',
    alpha3: 'NOR',
    numeric: '578'
  }
*/
```

Get country by ISO 3166-1 Alpha-3

```
use Jinas\ISO\ISO3166;

$iso = new ISO3166;
var_dump($iso->whereAlpha3('nor'));
/* Returns:
  {
    country: 'Norway',
    alpha2: 'NO',
    alpha3: 'NOR',
    numeric: '578'
  }
*/
```

Get country by ISO 3166-1 Numeric

```
use Jinas\ISO\ISO3166;

$iso = new ISO3166;
var_dump($iso->whereNumeric(578));
/* Returns:
  {
    country: 'Norway',
    alpha2: 'NO',
    alpha3: 'NOR',
    numeric: '578'
  }
*/
```

Get values by country name

```
use Jinas\ISO\ISO3166;

$iso = new ISO3166;
var_dump($iso->whereCountry("norway"));

/* Returns:
  {
    country: 'Norway',
    alpha2: 'NO',
    alpha3: 'NOR',
    numeric: '578'
  }
*/
```

### License

[](#license)

MIT © [Mohamed Jinas](https://jinas.me)

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

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

Unknown

Total

1

Last Release

2181d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/cf0464cf5ff5afa87f8940e92f2e9974200ef0939a3cd1a922bc3b5793850a06?d=identicon)[jinas123](/maintainers/jinas123)

---

Tags

countryiso-3166iso-3166-1php

### Embed Badge

![Health badge](/badges/jinas-iso-3166/health.svg)

```
[![Health](https://phpackages.com/badges/jinas-iso-3166/health.svg)](https://phpackages.com/packages/jinas-iso-3166)
```

###  Alternatives

[kitetail/zttp

A developer-experience focused HTTP client, optimized for most common use cases.

1.7k1.2M72](/packages/kitetail-zttp)[cpriego/valet-linux

A more enjoyable local development experience for Linux.

1.5k135.9k](/packages/cpriego-valet-linux)[freearhey/wikidata

A PHP client for working with Wikidata API.

5628.6k](/packages/freearhey-wikidata)[mvdnbrk/dhlparcel-php-api

DHL Parcel API client for PHP

3957.9k5](/packages/mvdnbrk-dhlparcel-php-api)[jofrysutanto/windsor

YAML-ised Configuration for ACF

549.2k](/packages/jofrysutanto-windsor)[agungsugiarto/codeigniter4-authentication

Provides an API for authentication and includes concrete authentication adapters for common use case scenarios

494.5k2](/packages/agungsugiarto-codeigniter4-authentication)

PHPackages © 2026

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