:globe_with_meridians: List of all countries with names and ISO 3166-1 codes in all languages and data formats.

Last update: Aug 7, 2022

symfony upgrade fixertwig gettext extractorwisdomcentipedepermissions handlerextraloadgravatarlocurrocountry listtransliterator

Country List

List of all countries with names and ISO 3166-1 codes in all languages and all data formats.

Formats Available

  • Text
  • JSON
  • YAML
  • XML
  • HTML
  • CSV
  • SQL
    • MySQL
    • PostgreSQL
    • SQLite
  • PHP
  • XLIFF

If you intend to use the package with PHP see this.

Multilingual

All formats are also available in multiple languages, please find full language list here.

Build

Country list is available out of the box, but if you want to submit patches, add new formats, update data source or contribute in any other way, you will probably want to rebuild the list:

$ docker-compose run php /var/www/html/bin/build -v

Other Interesting Lists

GitHub

https://github.com/umpirsky/country-list
Comments
  • 1. how to use

    Hi,

    Thanks for this. What's the proper way to use these in any project? As it's just lists and no actual classes, I'm not entirely sure how to use them? Or am I missing something?

    David.

    Reviewed by denjaland at 2017-10-07 13:20
  • 2. Using this package in PHP/Composer

    I'm not sure how this is supposed to be used with Composer. I don't think there is a reliable way to get the location (directory) of the data.

    The simplest way around this is with an auto-loaded class that can return the directory the data is located. Would you accept a PR with this addition?

    Edit: See my fork.

    Reviewed by MidnightDesign at 2016-02-11 10:35
  • 3. Watch out USSR in the list!

    Union of Soviet Socialist Republics... you are kidding!

    Thanks for snippet but after this (USSR) I will need to check each country if it is not a joke.

    Reviewed by igsm at 2015-06-23 14:05
  • 4. Class 'Locale' not found

    $ ./console build

    Fatal error: Class 'Locale' not found in /home/gadelat/tmp/country-list/vendor/symfony/locale/Symfony/Component/Locale/Locale.php on line 15

    Reviewed by ostrolucky at 2014-07-09 11:51
  • 5. Why requirements are PHP > 7.1 and not 7.0 ?

    Hey I have a regular Ubuntu stable release and I can't update your package because of PHP requirements. Is there a reason why 7.1 and not 7.0 ? Thanks

    Reviewed by hugsbrugs at 2018-02-14 15:52
  • 6. Finishing PHP country helper

    Hey @umpirsky

    I've finished the staled PR #99 by adding the requested exception for the file loader. Let me know if you need anything else.

    Cheers, Peter

    Reviewed by spekulatius at 2020-09-29 07:31
  • 7. [Proposal] One file with each country it its own language

    Fx.

    If I had chosen russia, I would not be able to find my own country again.

    So I would say it would be nice to have 1 file, with each country it is own language.

    Fx Germany = Deutschland Mexico = Mexicanos Denmark = Danmark Russia = Российская

    maybe put it in country/general/country.*

    Reviewed by lsv at 2014-07-18 12:27
  • 8. composer PHP requirements fails on PHP7

    In your composer file you are using ~5.4, which causes composer to fail when using PHP7. I assume there is not reason that the package should not be used on PHP7? If not I suggest to change to >=5.4

    Error when running composer:

    umpirsky/country-list dev-master requires php ~5.4 -> your PHP version (7.0.2) does not satisfy that requirement

    Reviewed by stadskle at 2016-03-26 07:02
  • 9. Missing countries for French language

    Hello, there are 4 missing countries in French version

    BQ => Bonaire, Saint-Eustache et Saba CW => Curaçao SS => Sud Soudan SX => Sint Maarten

    Thanks

    Reviewed by caouecs at 2013-11-20 22:25
  • 10. Adding country codes as well.

    This is a very good resource. It can be used for Registration forms and other purposes. It would be very good, if the country calling codes could be as well added to this list.

    Moreover, a string-array format for Android XML would be very good as well.

    Reviewed by crackjack at 2013-04-23 06:47
  • 11. Tag a release in master branch

    I have written a library that depends on country-list through composer and packagist. Now because there is no tagged release of country-list all projects that depend on my library must add "minimum-stability": "dev" to their composer.json.

    Adding a tag would solve this for me. Hope it's not to much trubble...

    Reviewed by hanneskod at 2013-01-31 20:44
  • 12. NPM package removed due to malicious code

    The NPM package (https://www.npmjs.com/package/@umpirsky/country-list) was removed because it apparently "contained malicious code". Clicking the link for more information on that page just gives a 404 though, so I couldn't find any more details. Does anyone know why this happened or if the package will ever be added back to NPM?

    Reviewed by mogzol at 2021-07-06 22:48
  • 13. How to contribute?

    Since my raised issue on #115 seems not going anywhere I decided by myself to contribute.

    But the readme isn't very detailed to how the countries list is generated.

    Can you please update the readme.md?

    Thank you

    Reviewed by Messhias at 2021-07-02 14:47
  • 14. Add UK alias for United Kingdom in the country list.

    The United Kingdom in the most of countries around the is known as the UK as well.

    But the UK it's a standard for the whole EU and some other countries in the Asia and middle-east (e.g. India, United Arab Emirates, and most countries was a UK colony in the history).

    Reviewed by Messhias at 2021-06-16 10:24
  • 15. Use UTF-8 for JSON

    The year is 2019, those refusing to use anything but ASCII should be the one to suffer, not the 99% of people whose systems are able to handle UTF-8. So instead of escaping all non ASCII characters on the data, they really should be just in plain, pretty, readable UTF-8.

    One might also consider pretty printing the json data.

    Reviewed by Huulivoide at 2019-06-17 08:57
  • 16. JSON is kind of useless unless it has proper key/values

    With JS frameworks, and more generally REST APIs/HTTP requests, the current JSON structures are not much help, since we can't programmatically target keys.

    How about this structure?

    [
        { 
            id: 'AF', 
            value:'Afghanistan' 
        },
        {
            id: 'ZA', 
            value:'Afrique du Sud' 
        },
    ...
    ]
    
    Reviewed by bonatoc at 2016-11-24 17:50
  • 17. Add a license in README

    Hi, I didn't found the the license explanation at your README file. I just found it on your composer file. Can you add your MIT license explanation on it? maybe just some enhancement to make us more clearly to understand. Thank you.

    Reviewed by mnafian at 2016-11-01 03:36
A PHP library providing ISO 3166-1 data

league/iso3166 A PHP library providing ISO 3166-1 data. What is ISO 3166-1 ISO 3166-1 is part of the ISO 3166 standard published by the International

Aug 13, 2022
YCOM Impersonate. Login as selected YCOM user 🧙‍♂️in frontend.

YCOM Impersonate Login as selected YCOM user in frontend. Features: Backend users with admin rights or YCOM[] rights, can be automatically logged in v

Jan 19, 2022
📦 "PHP type names" contains the list of constants for the available PHP data types.

PHP type names PHP type names ?? Description Simple library containing the list of constants for the available PHP data types. Use those constant type

Mar 18, 2022
🌐 A minimalist languages library that made plugins support multiple languages.

libLanguages · libLanguages is a PocketMine-MP library for making plugins support multiple languages. Easy To Learn: Just declare it in onEnable() fun

May 1, 2022
Import data from and export data to a range of different file formats and media

Ddeboer Data Import library This library has been renamed to PortPHP and will be deprecated. Please use PortPHP instead. Introduction This PHP library

Jun 24, 2022
This AddOn allows you to search for module names when adding a block
This AddOn allows you to search for module names when adding a block

Modulsuche und Modulvorschau für REDAXO 5 Dieses AddOn ermöglicht die Suche nach Modulnamen, wenn man einen Block hinzufügt. Dies kann sehr hilfreich

Jun 12, 2022
This package is used to validate the telephone numbers of the countries taken into account. It also makes it possible to verify that a number is indeed a number of an operator X

phone-number-checker This package is used to validate the telephone numbers of the countries taken into account. It also makes it possible to verify t

Feb 7, 2022
Helper for countries laravel package

Countries helper Helper for countries laravel package Installation You can install the package via composer: composer require eliseekn/countries-helpe

Oct 15, 2021
A comprehensive library for generating differences between two strings in multiple formats (unified, side by side HTML etc). Based on the difflib implementation in Python

PHP Diff Class Introduction A comprehensive library for generating differences between two hashable objects (strings or arrays). Generated differences

Aug 2, 2022
This repository contains academic codes from experiments and labs I did during my academic years.

Table Of Content Semester 3 Business Communication Skills Computer Graphics Digital Electronics and Logic Design Fundamentals of Data Structures Human

Aug 12, 2022
Verify purchase codes right on your WordPress dashboard.
Verify purchase codes right on your WordPress dashboard.

envato-purchase-code-widget Verify purchase codes right on your WordPress dashboard. Install the plugin Go to Settings->EPCW and enter your "Envato AP

Oct 28, 2021
A PHP web interface for scanning ISBN book codes, identify books with Antolin reading promotion offer

Ein PHP-Webinterface zum Scannen von ISBN-Buchcodes, identifiziere Bücher mit Antolin-Leseförderungs-Angebot. Einfache Installation. Für Mitarbeiter*innen in Schulbüchereien.

May 20, 2022
This project is very diverse and based upon many languages and libraries such as C++, Python, JavaScript, PHP and MQTT

ADMS-Real-time-project This project is very diverse and based upon many languages and libraries such as C++, Python, JavaScript, PHP and MQTT Advance_

Dec 1, 2021
Learning design patterns by implementing them in various programming languages.

design-patterns Learning design patterns by implementing them in various programming languages. Creational design patterns Creational design patterns

Dec 13, 2021
Parse your humble choice / monthly data and compile a CSV list for better overview

humbleparser Parse your humble choice / monthly data and compile a CSV list for better overview Requirements PHP CLI (>= 7.4)) php-curl Note I have ne

May 4, 2022
A list of ICs and IPs for AI, Machine Learning and Deep Learning.
A list of ICs and IPs for AI, Machine Learning and Deep Learning.

AI Chip (ICs and IPs) Editor S.T.(Linkedin) Welcome to My Wechat Blog StarryHeavensAbove for more AI chip related articles Latest updates Add news of

Aug 8, 2022
A curated list of awesome Laravel bookmarks, packages, tools, articles, tutorials and related resources.

ATTENTION: This list is obsolete and discontinued. Please find a much more comprehensive, much more well-maintained awesome-laravel list at chiraggude

Aug 5, 2022
DiscordLookup | Get more out of Discord with Discord Lookup! Snowflake Decoder, Guild List with Stats, Invite Info and more...
DiscordLookup | Get more out of Discord with Discord Lookup! Snowflake Decoder, Guild List with Stats, Invite Info and more...

DiscordLookup Get more out of Discord with Discord Lookup! Snowflake Decoder, Guild List with Stats, Invite Info and more... Website Getting Help Tool

Aug 4, 2022
Php-file-iterator - FilterIterator implementation that filters files based on a list of suffixes, prefixes, and other exclusion criteria.

php-file-iterator Installation You can add this library as a local, per-project dependency to your project using Composer: composer require phpunit/ph

Aug 14, 2022