PHPackages                             mehr-it/lara-countries - 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. [Localization &amp; i18n](/categories/localization)
4. /
5. mehr-it/lara-countries

ActiveLibrary[Localization &amp; i18n](/categories/localization)

mehr-it/lara-countries
======================

Extendable multilingual, countries list for Laravel

1.4.0(3y ago)01.4k[2 PRs](https://github.com/mehr-it/lara-countries/pulls)MITPHPPHP &gt;=7.1

Since Oct 25Pushed 3y agoCompare

[ Source](https://github.com/mehr-it/lara-countries)[ Packagist](https://packagist.org/packages/mehr-it/lara-countries)[ RSS](/packages/mehr-it-lara-countries/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (6)Versions (12)Used By (0)

Lara Countries
==============

[](#lara-countries)

[![Latest Version on Packagist](https://camo.githubusercontent.com/d6813f1066fb37daa3d1481e4f61ab91094c20bc3993b8fdb6045f23ca803751/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d6568722d69742f6c6172612d636f756e74726965732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/mehr-it/lara-countries)[![Build Status](https://camo.githubusercontent.com/e217f3976a32089e2bf4dfe52a2b1d5ec3d1b633b24fc198d6afac9a94bc7e0c/68747470733a2f2f7472617669732d63692e6f72672f6d6568722d69742f6c6172612d636f756e74726965732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/mehr-it/lara-countries)

Localized country and language list for Laravel with all ISO codes.

Country list contains following data:

- alpha-2 country code (ISO 3166-1)
- alpha-3 country code (ISO 3166-1)
- Country name (in all locales)
- Dialing code (eg. 49 for Germany)

Language list contaings following data:

- alpha-2 language code (ISO 639-1)
- Language name (in all locales)

Unlike many other packages, it does not use a hardcoded list but imports the selected data to the database. For faster performance the data is cached locally in PHP files which are synchronized via the central application cache.

This way you get best performance but are still free to edit data.

Installation
------------

[](#installation)

Install the package using composer. Laravel's package auto discovery will do the rest for you:

```
composer require  mehr-it/lara-countries

```

Import country data
-------------------

[](#import-country-data)

After installation you have to import data to the database: To import the country/language list, run following command:

```
artisan countries:import
artisan languages:import

```

This imports the country/language list. If you need any other locale than "en", you can import them using following command:

```
artisan countries:importLocale de
artisan languages:importLocale de

```

Usage
-----

[](#usage)

You can access country information using the `Countries` facade:

```
// get country information
Countries::get('US');

// get country information with other locale than the application locale
Countries::get('US', 'de');

// check if country code exists
Countries::exists('US');

// list all countries
Countries::all();

// list all countries with other locale than the application locale
Countries::all('de');

// list all iso2 codes
Countries::allIso2Codes();

```

You can access language information using the `Languages` facade:

```
// get language information
Languages::get('en');

// get language information with other locale than the application locale
Languages::get('en', 'de');

// check if language code exists
Languages::exists('US');

// list all languages
Languages::all();

// list all languages with other locale than the application locale
Languages::all('de');

// list all iso2 codes
Languages::allIso2Codes();

```

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity59

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

Every ~144 days

Recently: every ~192 days

Total

9

Last Release

1238d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/44973729?v=4)[mehr.IT GmbH](/maintainers/mehr-it)[@mehr-it](https://github.com/mehr-it)

---

Top Contributors

[![chmgr](https://avatars.githubusercontent.com/u/94837732?v=4)](https://github.com/chmgr "chmgr (2 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/mehr-it-lara-countries/health.svg)

```
[![Health](https://phpackages.com/badges/mehr-it-lara-countries/health.svg)](https://phpackages.com/packages/mehr-it-lara-countries)
```

###  Alternatives

[mcamara/laravel-localization

Easy localization for Laravel

3.5k9.1M112](/packages/mcamara-laravel-localization)[typicms/base

A modular multilingual CMS built with Laravel, enabling developers to manage structured content like pages, news, events, and more.

1.6k20.3k](/packages/typicms-base)[vemcogroup/laravel-translation

Translation package for Laravel to scan for localisations and up/download to poeditor

135304.0k2](/packages/vemcogroup-laravel-translation)

PHPackages © 2026

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