{
 "slug": "country-flag-emoji",
 "name": "Country Flag Emoji",
 "author": "Risan Bagja Pradana",
 "density": "full",
 "status": "active",
 "status_note": null,
 "alternatives_page": null,
 "one_liner": "JavaScript library listing country codes with their flag emojis, Unicode sequences and country names.",
 "category": {
  "slug": "emoji",
  "name": "Emoji"
 },
 "tags": [
  "Code library",
  "Open source"
 ],
 "styles": [],
 "logo_url": "https://agentgid.com/media/avatars/risan.png",
 "logo_letter": "C",
 "links": {
  "repo": "https://github.com/risan/country-flag-emoji",
  "website": null,
  "api_docs": null
 },
 "preview": {
  "kind": "image_grid",
  "src": "https://agentgid.com/assets/country-flag-emoji/demo.jpg",
  "alt": "A country menu filtered by \"uni\", a list of orders per country with names from get(), and the first 90 of the 258 entries by code, flags drawn with the Noto Color Emoji font.",
  "caption": "Made by AgentGid with country-flag-emoji 1.0.3 (npm, sha512 checked); flags drawn with NotoColorEmoji.ttf from googlefonts/noto-emoji tag v2020-09-16-unicode13_1. country-flag-emoji is MIT; the flag pictures come from Google's Noto Color Emoji font (SIL Open Font License 1.1), not from Apple or another platform; the order numbers are made up."
 },
 "verdicts": [
  {
   "key": "price",
   "label": "Price",
   "value": "Free",
   "status": "yes",
   "sub": "No paid plan",
   "quote": null,
   "note": "Free and open source under the MIT license.",
   "source": {
    "label": "github.com/risan/country-flag-emoji",
    "url": "https://github.com/risan/country-flag-emoji"
   },
   "n": 1
  },
  {
   "key": "commercial",
   "label": "Commercial use",
   "value": "Yes",
   "status": "yes",
   "sub": "MIT License",
   "quote": "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software",
   "note": "The MIT License allows use and selling in paid products.",
   "source": {
    "label": "LICENSE on GitHub",
    "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE"
   },
   "n": 2
  },
  {
   "key": "credit",
   "label": "Credit the author",
   "value": "Not needed",
   "status": "yes",
   "sub": "Keep the notice in code copies",
   "quote": "The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.",
   "note": "No credit on screen. Keep the license notice inside the code you ship.",
   "source": {
    "label": "LICENSE on GitHub",
    "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE"
   },
   "n": 3
  },
  {
   "key": "agent_access",
   "label": "Agent access",
   "value": "npm package",
   "status": "info",
   "sub": "Installs without a key",
   "quote": null,
   "note": "An agent can install it by itself with npm install country-flag-emoji. No key or account is needed.",
   "source": {
    "label": "github.com/risan/country-flag-emoji",
    "url": "https://github.com/risan/country-flag-emoji"
   },
   "n": 4
  }
 ],
 "license": {
  "name": "MIT License",
  "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE",
  "summary": "Free for personal and paid products under the MIT License, with no visible credit needed. Keep the short copyright and permission notice with copies of the code.",
  "pages_read": 1,
  "rules": [
   "Keep the MIT license and copyright notice with any copies or substantial portions you distribute.",
   "Install via npm (country-flag-emoji) or the unpkg CDN rather than copying data by hand.",
   "Look up flags by ISO 3166-1 alpha-2 country code with get()."
  ],
  "rows": [
   {
    "label": "Commercial use",
    "value": "Yes",
    "status": "yes",
    "quote": "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software",
    "source": {
     "label": "LICENSE on GitHub",
     "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE"
    },
    "note": null
   },
   {
    "label": "Credit",
    "value": "Not needed",
    "status": "yes",
    "quote": "The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.",
    "source": {
     "label": "LICENSE on GitHub",
     "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE"
    },
    "note": null
   },
   {
    "label": "Inside your app or game",
    "value": "Can ship inside your app",
    "status": "yes",
    "quote": "Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files",
    "source": {
     "label": "LICENSE on GitHub",
     "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE"
    },
    "note": null
   },
   {
    "label": "Pass the files on to your users",
    "value": "With conditions",
    "status": "cond",
    "quote": "The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.",
    "source": {
     "label": "LICENSE on GitHub",
     "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE"
    },
    "note": "Passing the files on is allowed with the MIT notice kept."
   },
   {
    "label": "AI training",
    "value": "Not stated",
    "status": "unknown",
    "quote": null,
    "source": null,
    "note": null
   },
   {
    "label": "Bots and bulk downloads",
    "value": "Not stated",
    "status": "unknown",
    "quote": null,
    "source": null,
    "note": null
   }
  ],
  "checked_at": "2026-11-11",
  "commercial_use_page": "https://agentgid.com/assets/country-flag-emoji/commercial-use/"
 },
 "overview": {
  "heading": "Country Flag Emoji: flags and names for every country code",
  "body": "Country Flag Emoji is a small free code library with a list of countries and regions. For each two-letter code like DE or JP it gives the name and the flag emoji. The flags are text characters, so the visitor's own emoji font draws them."
 },
 "uses": [
  {
   "title": "Flag next to a country code",
   "text": "Your database stores a two-letter code such as FR for each order or user. One call turns it into the country name and its flag for a table or a profile.",
   "idea": false,
   "image": null
  },
  {
   "title": "Country list for a form",
   "text": "Fill the country menu of a sign-up, shipping or billing form with every name and flag from one list. Typing a few letters can narrow it down.",
   "idea": false,
   "image": "https://agentgid.com/assets/country-flag-emoji/demo.jpg"
  },
  {
   "title": "Flags on a page without a build step",
   "text": "A plain HTML page, like a landing page or an old site, can load the library with one script tag and use the same list.",
   "idea": false,
   "image": null
  },
  {
   "title": "Sales or visitors by country",
   "text": "Put a flag in front of each country in a small report, such as orders per country, so people find their row at a glance.",
   "idea": true,
   "image": null
  },
  {
   "title": "Region switcher in the header",
   "text": "Show the flag of the chosen country in a shop's region or currency menu, next to its name, not instead of it.",
   "idea": true,
   "image": null
  }
 ],
 "start": {
  "prompt": "Add country-flag-emoji 1.0.3 and build a country menu for the checkout form from countryFlagEmoji.list, sorted by name, showing the flag and the name and saving the two-letter code; handle an unknown code (get() returns undefined).",
  "install": null,
  "install_note": null,
  "code": [
   {
    "tab": "Step 1",
    "intro": "Add the package to your project.",
    "source": "$ npm install country-flag-emoji"
   },
   {
    "tab": "Step 2",
    "intro": "Import it and look up a country by its two-letter code, or use the full list.",
    "source": "import countryFlagEmoji from \"country-flag-emoji\";\n\n// Array of all country flag emojis\nconsole.log(countryFlagEmoji.list);\n\n// Get country flag emoji for the given country code\nconsole.log(countryFlagEmoji.get(\"US\"));"
   }
  ]
 },
 "mistakes": [
  {
   "dont": "countryFlagEmoji.get(code).name with a code from user input",
   "fix": "const c = countryFlagEmoji.get(code); if (!c) show \"Unknown country\"",
   "why": "get() returns undefined for a code that is not in the list, so reading .name throws.",
   "dont_code": false,
   "fix_code": true
  },
  {
   "dont": "<script src=\"https://unpkg.com/country-flag-emoji@latest/dist/country-flag-emoji.umd.js\">",
   "fix": "Pin the version (country-flag-emoji@1.0.3) or install the package",
   "why": "The docs show @latest; a pinned version cannot change under your page.",
   "dont_code": true,
   "fix_code": false
  },
  {
   "dont": "Treat every entry of countryFlagEmoji.list as a country in a shipping form",
   "fix": "Filter the list against the countries you really ship to",
   "why": "In our demo the 258 entries include EU (European Union), UN (United Nations) and small territories such as AC and TA.",
   "dont_code": false,
   "fix_code": false
  },
  {
   "dont": "Use the flag emoji alone as the label of a menu item",
   "fix": "Show the country name next to the flag and keep the name as the accessible text",
   "why": "The flag is only an emoji character; its look depends on the device font and screen readers read it differently.",
   "dont_code": false,
   "fix_code": false
  }
 ],
 "agent": {
  "self_serve": true,
  "self_serve_text": "Agent installs a package or loads it from a CDN",
  "install": "npm install country-flag-emoji",
  "repo": "https://github.com/risan/country-flag-emoji",
  "api_docs": null,
  "api_account": "Not needed. Everything runs on your side.",
  "get_files": null,
  "formats": [],
  "limits": null,
  "mcp": null,
  "mcp_url": null,
  "credit_line": "Country data: country-flag-emoji, MIT License",
  "rules_text": "- Country Flag Emoji (Emoji). JavaScript library listing country codes with their flag emojis, Unicode sequences and country names. Price: free; commercial use OK; no credit needed.\n  Connect: npm country-flag-emoji.\n  Rule: Keep the MIT license and copyright notice with any copies or substantial portions you distribute.\n  Rule: Install via npm (country-flag-emoji) or the unpkg CDN rather than copying data by hand.\n  Rule: Look up flags by ISO 3166-1 alpha-2 country code with get().\n  License: https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE (checked 2026-11-11; details: https://agentgid.com/assets/country-flag-emoji/)",
  "agent_md": "https://agentgid.com/assets/country-flag-emoji/agent.md",
  "card_json": "https://agentgid.com/assets/country-flag-emoji/card.json"
 },
 "popularity": {
  "gid_score": 20,
  "stars": 40,
  "downloads_7d": 11304,
  "downloads_7d_label": "11.3K",
  "downloads_change_4w_pct": 18.2,
  "eco": "npm",
  "package": "country-flag-emoji",
  "repo": "risan/country-flag-emoji",
  "agent_projects": null,
  "agent_projects_total": null,
  "downloads_unconfirmed": true,
  "series": {
   "downloads_weekly": [
    [
     "2025-11-17",
     6007
    ],
    [
     "2025-11-24",
     6361
    ],
    [
     "2025-12-01",
     6163
    ],
    [
     "2025-12-08",
     7198
    ],
    [
     "2025-12-15",
     6120
    ],
    [
     "2025-12-22",
     3212
    ],
    [
     "2025-12-29",
     2483
    ],
    [
     "2026-01-05",
     4635
    ],
    [
     "2026-01-12",
     6072
    ],
    [
     "2026-01-19",
     6808
    ],
    [
     "2026-01-26",
     6525
    ],
    [
     "2026-02-02",
     8434
    ],
    [
     "2026-02-09",
     7892
    ],
    [
     "2026-02-16",
     7171
    ],
    [
     "2026-02-23",
     8925
    ],
    [
     "2026-03-02",
     9544
    ],
    [
     "2026-03-09",
     8430
    ],
    [
     "2026-03-16",
     6574
    ],
    [
     "2026-03-23",
     7270
    ],
    [
     "2026-03-30",
     6519
    ],
    [
     "2026-04-06",
     6625
    ],
    [
     "2026-04-13",
     6304
    ],
    [
     "2026-04-20",
     5805
    ],
    [
     "2026-04-27",
     6826
    ],
    [
     "2026-05-04",
     6326
    ],
    [
     "2026-05-11",
     6046
    ],
    [
     "2026-05-18",
     5581
    ],
    [
     "2026-05-25",
     6143
    ],
    [
     "2026-06-01",
     6837
    ],
    [
     "2026-06-08",
     6109
    ],
    [
     "2026-06-15",
     6192
    ],
    [
     "2026-06-22",
     6019
    ],
    [
     "2026-06-29",
     5061
    ],
    [
     "2026-07-06",
     4950
    ],
    [
     "2026-07-13",
     5896
    ],
    [
     "2026-07-20",
     5792
    ],
    [
     "2026-07-27",
     4699
    ],
    [
     "2026-08-03",
     6595
    ],
    [
     "2026-08-10",
     6187
    ],
    [
     "2026-08-17",
     5206
    ],
    [
     "2026-08-24",
     5829
    ],
    [
     "2026-08-31",
     6177
    ],
    [
     "2026-09-07",
     5185
    ],
    [
     "2026-09-14",
     5137
    ],
    [
     "2026-09-21",
     7390
    ],
    [
     "2026-09-28",
     8295
    ],
    [
     "2026-10-05",
     8910
    ],
    [
     "2026-10-12",
     6977
    ],
    [
     "2026-10-19",
     7771
    ],
    [
     "2026-10-26",
     9435
    ],
    [
     "2026-11-02",
     9687
    ],
    [
     "2026-11-09",
     10434
    ]
   ],
   "stars": []
  },
  "stars_flat_since": "2026-11-12",
  "updated_at": "2026-11-19"
 },
 "alternatives": [
  {
   "slug": "country-flag-emoji",
   "name": "Country Flag Emoji",
   "why": null,
   "current": true,
   "price": "Free",
   "commercial": {
    "value": "Commercial OK",
    "status": "yes"
   },
   "access": "npm"
  },
  {
   "slug": "emojibase",
   "name": "Emojibase",
   "why": "Pick Emojibase when you need emoji and flag names in several languages, not only English.",
   "current": false,
   "price": "Free",
   "commercial": {
    "value": "Commercial OK",
    "status": "yes"
   },
   "access": "npm"
  },
  {
   "slug": "emoji-mart",
   "name": "Emoji Mart",
   "why": "Pick Emoji Mart when people should choose any emoji from a ready picker, not only flags.",
   "current": false,
   "price": "Free",
   "commercial": {
    "value": "Commercial OK",
    "status": "yes"
   },
   "access": "npm"
  },
  {
   "slug": "twemoji",
   "name": "Twemoji",
   "why": "Pick Twemoji when emoji, flags included, must look the same as pictures on every device.",
   "current": false,
   "price": "Free",
   "commercial": {
    "value": "Commercial OK",
    "status": "yes"
   },
   "access": "npm"
  },
  {
   "slug": "emojilib",
   "name": "emojilib",
   "why": "Keyword library that makes emoji searchable, mapping each emoji character to a list of keywords.",
   "current": false,
   "price": "Free",
   "commercial": {
    "value": "Commercial OK",
    "status": "yes"
   },
   "access": "npm"
  },
  {
   "slug": "emoji-datasource",
   "name": "Emoji Datasource",
   "why": "Emoji data in JSON plus spritesheet images from Apple, Google, Twitter and Facebook sets, distributed on GitHub and npm.",
   "current": false,
   "price": "Free",
   "commercial": {
    "value": "With conditions",
    "status": "cond"
   },
   "access": "npm"
  }
 ],
 "faq": [
  {
   "q": "Can I use it in a paid app?",
   "a": "Yes. The MIT License allows use, copying and selling; keep the copyright and permission notice with copies of the code."
  },
  {
   "q": "Which codes does it use?",
   "a": "Two-letter codes in the ISO 3166-1 alpha-2 format, such as US or ID."
  },
  {
   "q": "What does one entry contain?",
   "a": "Four fields, code, unicode (the character sequence), name and emoji."
  },
  {
   "q": "Is it still updated?",
   "a": "The newest version on the package registry is 1.0.3, published in October 2019."
  }
 ],
 "at_a_glance": {
  "latest_version": "1.0.3",
  "last_commit": "2020-02-14",
  "runtime": "Node.js 10+ for the server build; in the browser the dist/country-flag-emoji.umd.js file works with a plain script tag.",
  "key_needed": false
 },
 "good_to_know": [
  "The last release, 1.0.3, came out in October 2019, so newer changes to country lists are not in it.",
  "It holds codes, names and emoji characters only, no flag pictures. How a flag looks depends on the emoji font of the visitor's device.",
  "Names are in English only, such as \"United States\"; there are no translated names.",
  "Looking up a code that is not in the list gives nothing back, so the page must handle a missing country."
 ],
 "stack_snippets": [],
 "claims": [],
 "checked": {
  "license_read": "2026-11-11",
  "overview_checked": "2026-11-19",
  "numbers_updated": "2026-11-19",
  "sources": [
   {
    "label": "github.com/risan/country-flag-emoji",
    "url": "https://github.com/risan/country-flag-emoji"
   },
   {
    "label": "README on GitHub",
    "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/README.md"
   },
   {
    "label": "LICENSE on GitHub",
    "url": "https://github.com/risan/country-flag-emoji/blob/HEAD/LICENSE"
   },
   {
    "label": "npm: country-flag-emoji",
    "url": "https://registry.npmjs.org/country-flag-emoji"
   },
   {
    "label": "npm: country-flag-emoji/1.0.3",
    "url": "https://registry.npmjs.org/country-flag-emoji/1.0.3"
   }
  ],
  "unverified": null
 },
 "user_reports": null,
 "url": "https://agentgid.com/assets/country-flag-emoji/",
 "note": "Written by AgentGid from the official pages in checked.sources; quotes are copied from those pages. status: yes | cond | no | unknown | info. Prices and vendor claims are as reported on the checked date. Not legal advice."
}
