PHPackages                             pola5h/laravel-flags - 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. [Image &amp; Media](/categories/media)
4. /
5. pola5h/laravel-flags

ActiveLibrary[Image &amp; Media](/categories/media)

pola5h/laravel-flags
====================

A Laravel package for country and language flag icons.

019HTMLCI passing

Since Mar 5Pushed 2mo agoCompare

[ Source](https://github.com/Pola5h/FlagIcons)[ Packagist](https://packagist.org/packages/pola5h/laravel-flags)[ RSS](/packages/pola5h-laravel-flags/feed)WikiDiscussions main Synced 1mo ago

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

Pola5h/FlagIcons
================

[](#pola5hflagicons)

A Laravel package for country and language flag icons using the Twitter Emoji Twemoji Set.

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

[](#installation)

You can install the package via Composer. Run the following command:

```
composer require pola5h/laravel-flags
```

### Service Provider

[](#service-provider)

If you are using Laravel 5.5 or later, the package will automatically register the service provider. For earlier versions, add the service provider to your `config/app.php` file:

```
'providers' => [
    // Other service providers...
    FlagIcons\FlagIconsServiceProvider::class,
];
```

### Blade Component Usage

[](#blade-component-usage)

You can use the Blade component to display flag icons. The component supports displaying both country and language flags.

#### Syntax

[](#syntax)

```

```

#### Parameters

[](#parameters)

- **type**: The type of flag. Use "country" for country flags and "language" for language flags.
- **code**: The ISO 2 code for the flag (e.g., "bd" for Bangladesh, "bn" for Bengali language).
- **width** (optional): The width of the flag icon. Defaults to "auto".
- **height** (optional): The height of the flag icon. Defaults to "auto".

### Example

[](#example)

To display the flag of Bangladesh with a width of 10px and height of 10px:

```

```

To display the Bengali language flag with a width of 10px and height of 10px:

```

```

#### Dynamic Examples

[](#dynamic-examples)

You can also use dynamic values to render icons:

To display the country flag:

```

```

or

```

```

To display the language flag:

```

```

or

```

```

#### County List With Code

[](#county-list-with-code)

\[If you can't see the table, visit GitHub repo\]

Country NameCountry CodeAfghanistanafAlbaniaalAlgeriadzAmerican SamoaasAndorraadAngolaaoAnguillaaiAntarcticaaqAntigua and BarbudaagArgentinaarArmeniaamArubaawAscension IslandacAustraliaauAustriaatAzerbaijanazBahamasbsBahrainbhBangladeshbdBarbadosbbBelarusbyBelgiumbeBelizebzBeninbjBermudabmBhutanbtBolivia, Plurinational State ofboBonaire, Sint Eustatius and SababqBosnia and HerzegovinabaBotswanabwBouvet IslandbvBrazilbrBritish Indian Ocean TerritoryioBrunei DarussalambnBulgariabgBurkina FasobfBurundibiCabo VerdecvCambodiakhCamerooncmCanadacaCentral African RepubliccfChileclChinacnChristmas IslandcxCocos (Keeling) IslandsccColombiacoComoroskmCongocgCongo, The Democratic Republic of thecdCook IslandsckCosta RicacrCroatiahrCubacuCuraçaocwCypruscyCzechiaczCôte d'IvoireciDenmarkdkDjiboutidjDominicadmDominican RepublicdoEcuadorecEgyptegEl SalvadorsvEquatorial GuineagqEritreaerEstoniaeeEswatiniszEthiopiaetFalkland Islands (Malvinas)fkFaroe IslandsfoFijifjFinlandfiFrancefrFrench GuianagfFrench PolynesiapfFrench Southern TerritoriestfGabongaGambiagmGeorgiageGermanydeGhanaghGibraltargiGreecegrGreenlandglGrenadagdGuadeloupegpGuamguGuatemalagtGuernseyggGuineagnGuinea-BissaugwGuyanagyHaitihtHeard Island and McDonald IslandshmHoly See (Vatican City State)vaHondurashnHong KonghkHungaryhuIcelandisIndiainIndonesiaidIran, Islamic Republic ofirIraqiqIrelandieIsle of ManimItalyitJamaicajmJapanjpJerseyjeJordanjoKazakhstankzKenyakeKiribatikiKorea, Democratic People's Republic ofkpKorea, Republic ofkrKosovoxkKuwaitkwKyrgyzstankgLao People's Democratic RepubliclaLatvialvLebanonlbLesotholsLiberialrLibyalyLiechtensteinliLithuanialtLuxembourgluMacaomoMadagascarmgMalawimwMalaysiamyMaldivesmvMalimlMaltamtMarshall IslandsmhMauritaniamrMauritiusmuMayotteytMexicomxMicronesia, Federated States offmMoldova, Republic ofmdMonacomcMongoliamnMontenegromeMontserratmsMoroccomaMozambiquemzMyanmarmmNamibianaNaurunrNepalnpNetherlandsnlNew CaledoniancNew ZealandnzNicaraguaniNigerneNigeriangNiuenuNorfolk IslandnfNorth MacedoniamkNorwaynoOmanomPakistanpkPalaupwPalestine, State ofpsPanamapaPapua New GuineapgParaguaypyPerupePhilippinesphPolandplPortugalptPuerto RicoprQatarqaRomaniaroRussian FederationruRwandarwRéunionreSaint BarthélemyblSaint Kitts and NevisknSaint LucialcSaint Martin (French part)mfSaint Pierre and MiquelonpmSaint Vincent and the GrenadinesvcSamoawsSan MarinosmSao Tome and PrincipestSaudi ArabiasaSenegalsnSerbiarsSeychellesscSierra LeoneslSingaporesgSint Maarten (Dutch part)sxSlovakiaskSloveniasiSolomon IslandssbSomaliasoSouth AfricazaSouth Georgia and the South Sandwich IslandsgsSouth SudanssSpainesSri LankalkSudansdSurinamesrSwedenseSwitzerlandchSyrian Arab RepublicsyTaiwan, Province of ChinatwTajikistantjTanzania, United Republic oftzThailandthTimor-LestetlTogotgTokelautkTongatoTrinidad and TobagottTunisiatnTurkmenistantmTurks and Caicos IslandstcTuvalutvTürkiyetrUgandaugUkraineuaUnited Arab EmiratesaeUnited KingdomgbUnited StatesusUnited States Minor Outlying IslandsumUruguayuyUzbekistanuzVanuatuvuVenezuela, Bolivarian Republic ofveViet NamvnVirgin Islands, BritishvgVirgin Islands, U.S.viWallis and FutunawfWestern SaharaehYemenyeZambiazmZimbabwezwÅland Islandsax#### Language List With Code

[](#language-list-with-code)

The language flags are selected based on the country with the highest number of speakers of that language. For example, while Bangla is spoken in both Bangladesh and India, the flag of Bangladesh is used for Bangla because it has more speakers there.

\[If you can't see the table, visit GitHub repo\]

Language NameLanguage CodeCountry NameCountry CodeAfrikaansafSouth AfricazaAmharicamEthiopiaetArabicarSaudi ArabiasaAzerbaijaniazAzerbaijanazBelarusianbeBelarusbyBulgarianbgBulgariabgBengalibnBangladeshbdBosnianbsBosnia and HerzegovinabaCatalancaSpainesCzechcsCzechiaczWelshcyUnited KingdomgbDanishdaDenmarkdkGermandeGermanydeModern Greek (1453-)elGreecegrEnglishenUnited StatesusSpanishesSpainesEstonianetEstoniaeePersianfaIran, Islamic Republic ofirFinnishfiFinlandfiFilipinofilPhilippinesphFrenchfrFrancefrGalicianglSpainesGujaratiguIndiainHindihiIndiainCroatianhrCroatiahrHungarianhuHungaryhuArmenianhyArmeniaamIndonesianidIndonesiaidIgboigNigeriangIcelandicisIcelandisItalianitItalyitJapanesejaJapanjpGeorgiankaGeorgiageKazakhkkKazakhstankzKhmerkmCambodiakhKannadaknIndiainKoreankoKorea, Republic ofkrKurdishkuTürkiyetrKirghizkyKyrgyzstankgLaoloLao People's Democratic RepubliclaLithuanianltLithuanialtLatvianlvLatvialvMalagasymgMadagascarmgMaorimiNew ZealandnzMacedonianmkNorth MacedoniamkMalayalammlIndiainMongolianmnMongoliamnMarathimrIndiainMalay (macrolanguage)msMalaysiamyMaltesemtMaltamtBurmesemyMyanmarmmNepali (macrolanguage)neNepalnpDutchnlNetherlandsnlNorwegiannoNorwaynoOriya (macrolanguage)orIndiainPanjabipaIndiainPolishplPolandplPushtopsAfghanistanafPortugueseptPortugalptRomanianroRomaniaroRussianruRussian FederationruSindhisdPakistanpkSinhalasiSri LankalkSlovakskSlovakiaskSlovenianslSloveniasiSomalisoSomaliasoAlbaniansqAlbaniaalSerbiansrSerbiarsSwedishsvSwedenseSwahili (macrolanguage)swKenyakeTamiltaIndiainTeluguteIndiainThaithThailandthTigrinyatiEritreaerTurkmentkTurkmenistantmTurkishtrTürkiyetrUkrainianukUkraineuaUrduurPakistanpkUzbekuzUzbekistanuzVietnameseviViet NamvnXhosaxhSouth AfricazaYiddishyiUnited StatesusYorubayoNigeriangChinesezhChinacnZuluzuSouth AfricazaAbkhazianabGeorgiageAfaraaEthiopiaetAkanakGhanaghAragoneseanSpainesAssameseasIndiainAvaricavRussian FederationruAvestanaeIran, Islamic Republic ofirAymaraayBolivia, Plurinational State ofboBambarabmMalimlBashkirbaRussian FederationruBiharibhIndiainBislamabiVanuatuvuBretonbrFrancefrChamorrochGuamguChechenceRussian FederationruNyanjanyMalawimwSimplified ChinesehansChinacnTraditional ChinesehantTaiwan, Province of ChinatwChuvashcvRussian FederationruCornishkwUnited KingdomgbCorsicancoFrancefrCreecrCanadacaDhivehidvMaldivesmvDzongkhadzBhutanbtEweeeTogotgFaroesefoFaroe IslandsfoFijianfjFijifjFulahffNigeriangScottish GaelicgdUnited KingdomgbManxgvIsle of ManimKalaallisutklGreenlandglGuaranignParaguaypyHaitianhtHaitihtHausahaNigeriangHererohzNamibianaHiri MotuhoPapua New GuineapgIdoioBritish Indian Ocean TerritoryioInterlingueieIrelandieInuktitutiuCanadacaInupiaqikUnited StatesusIrishgaIrelandieJavanesejvIndonesiaidKanurikrNigeriangKashmiriksIndiainKikuyukiKenyakeKinyarwandarwRwandarwRundirnBurundibiKomikvRussian FederationruKongokgCongo, The Democratic Republic of thecdKuanyamakjAngolaaoLatinlaHoly See (Vatican City State)vaLimburganliNetherlandsnlLingalalnCongo, The Democratic Republic of thecdLuba-KatangaluCongo, The Democratic Republic of thecdGandalgUgandaugLuxembourgishlbLuxembourgluMarshallesemhMarshall IslandsmhMoldovanmoMoldova, Republic ofmdNaurunaNaurunrNavajonvUnited StatesusNdongangAngolaaoNorth NdebelendZimbabwezwNorwegian BokmålnbNorwaynoNorwegian NynorsknnNorwaynoSichuan YiiiChinacnOccitan (post 1500)ocFrancefrOjibwaojCanadacaChurch SlaviccuBulgariabgOromoomEthiopiaetOssetianosRussian FederationruPalipiIndiainQuechuaquPerupeRomanshrmSwitzerlandchNorthern SamiseNorwaynoSamoansmAmerican SamoaasSangosgCentral African RepubliccfSanskritsaIndiainSerbo-CroatianshSerbiarsSouthern SothostSouth AfricazaTswanatnSouth AfricazaShonasnZimbabwezwSwatissEswatiniszSouth NdebelenrSouth AfricazaSundanesesuIndonesiaidTagalogtlPhilippinesphTahitiantyFrench PolynesiapfTajiktgTajikistantjTatarttRussian FederationruTonga (Tonga Islands)toTongatoTsongatsSouth AfricazaTwitwGhanaghUighurugChinacnVendaveSouth AfricazaWalloonwaBelgiumbeWolofwoSenegalsnWestern FrisianfyNetherlandsnlZhuangzaChinacnLicense
-------

[](#license)

This package is licensed under the MIT License. See the LICENSE file for more details.

Author
------

[](#author)

Kamruzzaman Polash (GitHub: @pola5h)

Acknowledgements
----------------

[](#acknowledgements)

This package uses the Twitter Emoji Twemoji Set for flag icons.

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance58

Moderate activity, may be stable

Popularity6

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity15

Early-stage or recently created project

 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 ~0 days

Total

2

Last Release

612d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/42013158555a8d21ac0261230c5f6cb76e713bafc4f416c4d184579d2c2df479?d=identicon)[polash](/maintainers/polash)

---

Top Contributors

[![Pola5h](https://avatars.githubusercontent.com/u/81049021?v=4)](https://github.com/Pola5h "Pola5h (6 commits)")

### Embed Badge

![Health badge](/badges/pola5h-laravel-flags/health.svg)

```
[![Health](https://phpackages.com/badges/pola5h-laravel-flags/health.svg)](https://phpackages.com/packages/pola5h-laravel-flags)
```

###  Alternatives

[milon/barcode

Barcode generator like Qr Code, PDF417, C39, C39+, C39E, C39E+, C93, S25, S25+, I25, I25+, C128, C128A, C128B, C128C, 2-Digits UPC-Based Extention, 5-Digits UPC-Based Extention, EAN 8, EAN 13, UPC-A, UPC-E, MSI (Variation of Plessey code)

1.5k13.3M39](/packages/milon-barcode)[bkwld/croppa

Image thumbnail creation through specially formatted URLs for Laravel

510496.0k23](/packages/bkwld-croppa)[char0n/ffmpeg-php

PHP wrapper for FFmpeg application

495225.1k1](/packages/char0n-ffmpeg-php)[goat1000/svggraph

Generates SVG graphs

132849.6k3](/packages/goat1000-svggraph)[cohensive/embed

Media Embed (for Laravel or as a standalone).

120370.4k](/packages/cohensive-embed)[netresearch/rte-ckeditor-image

Image support in CKEditor for the TYPO3 ecosystem - by Netresearch

63991.3k4](/packages/netresearch-rte-ckeditor-image)

PHPackages © 2026

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