250 countries · 5,000+ states · 150,000+ cities

Geographic data at your fingertips

Search 250 countries, 5,000+ states, and 150,000+ cities. Generate React components, seed databases, and explore geographic data — all from your terminal.

$ npm install -g @countrystatecity/cli COPY
csc — zsh
$ csc search countries --filter india
┌──────┬──────┬───────┬───────────┬───────┬──────────┐
│ ISO2ISO3NameCapitalPhoneCurrency │
├──────┼──────┼───────┼───────────┼───────┼──────────┤
│ ININDIndiaNew Delhi+91INR      │
└──────┴──────┴───────┴───────────┴───────┴──────────┘
Usage: 48/1,000 today
csc — zsh
🔍
Search
csc search countries
Browse and filter countries, states, cities with instant table output.
🌎
Explore
csc explore
Interactive drill-down browser with fuzzy search and arrow-key navigation.
Generate
csc generate dropdown
Generate React dropdown components with embedded geographic data.
🌱
Seed
csc generate seed
Generate Prisma seed files ready for database migration.
📦
Export
csc export
Export data in JSON, CSV, SQL, and more via the export tool.
📊
Usage
csc usage
Track API quota with colored progress bars and tier info.
🔑
Auth
csc auth login
Securely store and manage your API key.
🤖
AI-Ready
csc search --json
Machine-readable JSON output for AI agents and scripting.
1
Install
npm i -g @countrystatecity/cli
One command. Requires Node.js 18+.
2
Login
csc auth login
Authenticate with your API key from the dashboard.
3
Search
csc search countries
Browse all 250 countries instantly.
Simple, transparent pricing
Start free. Upgrade as you grow. No credit card required.
Plan Price Daily Monthly
Community Free Free 100 3,000
Starter Paid $5/mo 300 9,000
Supporter Paid $9/mo 1,000 30,000
Professional Paid $29/mo 3,300 100,000
Business Paid $79/mo 25,000 750,000
Get Your API Key