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

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

ishdidev/country
================

A simple library to list countries.

v1.0.0(2y ago)091MITPHPPHP ^7.4||^8.0

Since Mar 31Pushed 2y ago1 watchersCompare

[ Source](https://github.com/ishdidev/country)[ Packagist](https://packagist.org/packages/ishdidev/country)[ Docs](https://github.com/ishdidev/country)[ RSS](/packages/ishdidev-country/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

Getting started
===============

[](#getting-started)

This repository contains standalone PHP country classes. This can be used for listing countires, states, currency, continent, languages, phone code etc.

#### Installation

[](#installation)

```
composer require ishdidev/country

```

Available Methods
-----------------

[](#available-methods)

```
$country = new Country();

//List all countries
$countryList = $country->getCountries();

//Get Data
$countryName = $country->getData('IN', Country::COUNTRY_NAME);

$countryCode = $country->getData('India', Country::COUNTRY_CODE);

$phoneCode = $country->getData('IN', Country::COUNTRY_PHONE);

$countryState = $country->getData('IN', Country::COUNTRY_STATE);

$countryLanguages = $country->getData('IN', Country::COUNTRY_LANGUAGE_ALL);

$countryLanguage = $country->getData('IN', Country::COUNTRY_LANGUAGE_MAIN);

$countryContinent = $country->getData('IN', Country::COUNTRY_CONTINENT);

$countryCurrency = $country->getData('IN', Country::COUNTRY_CURRENCY);

$countryCapital = $country->getData('IN', Country::COUNTRY_CAPITAL);

//List all languages

$language = new Language();

$languageList = $language->list();

//List all currencies

$currency = new Currency();

$currencyList = $currency->list();

//List all continents

$continentList = $country->listContinent();
```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

776d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/13718bafc98b6751444f5759b56fb4008aee28d26627fd3aca232be29dff5497?d=identicon)[ishdidev](/maintainers/ishdidev)

---

Top Contributors

[![ishdidev](https://avatars.githubusercontent.com/u/158827413?v=4)](https://github.com/ishdidev "ishdidev (3 commits)")

---

Tags

phpcountry

### Embed Badge

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

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

###  Alternatives

[imanghafoori/laravel-anypass

A minimal yet powerful package to help you in development.

21421.6k](/packages/imanghafoori-laravel-anypass)[sun/country

Sun Country is the package that helps you to get the country name &amp; dialing code by the country ISO 3166-1 Alpha-2 code.

1016.5k](/packages/sun-country)

PHPackages © 2026

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