PHPackages                             woutersioen/country-list - 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. woutersioen/country-list

Abandoned → [symfony/intl](/?search=symfony%2Fintl)ArchivedLibrary[Utility &amp; Helpers](/categories/utility)

woutersioen/country-list
========================

A wrapper around https://github.com/umpirsky/country-list to easily fetch a list of countries in a certain language or get a specific country by country code and language.

1.0.1(10y ago)34.3k1[1 issues](https://github.com/WouterSioen/country-list/issues)MITPHPPHP &gt;=5.3

Since Sep 23Pushed 10y ago1 watchersCompare

[ Source](https://github.com/WouterSioen/country-list)[ Packagist](https://packagist.org/packages/woutersioen/country-list)[ Docs](https://github.com/WouterSioen/country-list)[ RSS](/packages/woutersioen-country-list/feed)WikiDiscussions master Synced 3w ago

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

[![Build Status](https://camo.githubusercontent.com/b71eeaca3a568f4ceb62494b7abbf46b1a1ec80affaba7015f74524e14b28049/68747470733a2f2f7472617669732d63692e6f72672f576f7574657253696f656e2f636f756e7472792d6c6973742e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/WouterSioen/country-list)

Abandoned
=========

[](#abandoned)

You can do the same things as with this package using the symfony/intl component

Country list
============

[](#country-list)

A wrapper around  to easily fetch a list of countries in a certain language or get a specific country by country code and language.

Installing
==========

[](#installing)

composer.json

```
{
    "require": {
        "woutersioen/country-list": "dev-master"
    }
}
```

index file for your project

```
// update this to the path to the "vendor/" directory, relative to this file
require_once '../vendor/autoload.php';
```

Usage
=====

[](#usage)

### With dependency injection container:

[](#with-dependency-injection-container)

First add an instance of the class `Sioen\Countries` to your dependency injection container.

```
// fetch an array of countries in a language
$languages = $this->getContainer()->get('countries')->getForLanguage('en');

// fetch one country in a language
$language = $this->getContainer()->get('countries')->getSpecificForLanguage('be', 'en');
// returns 'Belgium'
```

Most modern PHP Frameworks have a dependency injection container. This is the prefered way, since there will only be one instance of the countries object, and data will be cached in this object.

### PHP 5.4 (+)

[](#php-54-)

```
use Sioen\Countries;

// fetch an array of countries in a language
$languages = (new Countries)->getForLanguage('en');

// fetch one country in a language
$language = (new Countries)->getSpecificForLanguage('be', 'en');
// returns 'Belgium'
```

### PHP 5.3

[](#php-53)

```
use Sioen\ContryList;

$countries = new Countries();

// fetch an array of countries in a language
$languages = $countries->getForLanguage('en');

// fetch one country in a language
$language = $countries->getSpecificForLanguage('be', 'en');
// returns 'Belgium'
```

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance13

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 87.5% 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 ~168 days

Total

3

Last Release

3965d ago

Major Versions

0.1 → 1.0.02015-08-11

### Community

Maintainers

![](https://www.gravatar.com/avatar/47020dbad12c7484fcbf5d489573b7d67a3a9f479d7b3f47b314e8bf4372aab5?d=identicon)[WouterSioen](/maintainers/WouterSioen)

---

Top Contributors

[![WouterSioen](https://avatars.githubusercontent.com/u/1398405?v=4)](https://github.com/WouterSioen "WouterSioen (14 commits)")[![Grafikart](https://avatars.githubusercontent.com/u/395137?v=4)](https://github.com/Grafikart "Grafikart (1 commits)")[![timkant](https://avatars.githubusercontent.com/u/75654?v=4)](https://github.com/timkant "timkant (1 commits)")

---

Tags

countries

### Embed Badge

![Health badge](/badges/woutersioen-country-list/health.svg)

```
[![Health](https://phpackages.com/badges/woutersioen-country-list/health.svg)](https://phpackages.com/packages/woutersioen-country-list)
```

###  Alternatives

[rinvex/countries

Rinvex Countries is a simple and lightweight package for retrieving country details with flexibility. A whole bunch of data including name, demonym, capital, iso codes, dialling codes, geo data, currencies, flags, emoji, and other attributes for all 250 countries worldwide at your fingertips.

1.7k8.0M62](/packages/rinvex-countries)[league/iso3166

ISO 3166-1 PHP Library

69938.4M141](/packages/league-iso3166)[pragmarx/countries

PHP Countries and Currencies

1.9k3.4M24](/packages/pragmarx-countries)[webpatser/laravel-countries

Modern Laravel Countries package providing ISO 3166-2, ISO 3166-3, currency, capital and more for all countries. Compatible with Laravel 11.x, 12.x, and 13.x.

8602.9M10](/packages/webpatser-laravel-countries)[dougsisk/laravel-country-state

Country &amp; state helper for Laravel.

1731.9M](/packages/dougsisk-laravel-country-state)[pragmarx/countries-laravel

Countries for Laravel

1491.1M2](/packages/pragmarx-countries-laravel)

PHPackages © 2026

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