Afghanistan Provinces, Districts, and Villages Data is a vital open-source resource that provides reliable, structured, and up-to-date geographic and demographic information—crucial for developers, researchers, policymakers, and humanitarian organizations in today’s data-driven world. One remarkable initiative filling this need for Afghanistan is the open-source project titled Afghanistan Provinces, Districts, and Villages Data, hosted on GitHub by danishyarkhwork. This dataset provides a well-organized JSON-based structure detailing Afghanistan’s administrative divisions—from provinces to districts—with future plans to include village-level data.
Whether you are building a data visualization application, conducting regional research, developing a WordPress plugin, or integrating APIs for regional services in Afghanistan, this project offers an essential starting point.
What Is the Afghanistan Provinces, Districts, and Villages Dataset?

This GitHub repository contains comprehensive, structured data for all provinces and districts in Afghanistan. The data is presented in JSON format, making it highly accessible for developers and data analysts alike. It includes details such as population statistics, administrative boundaries, ethnic compositions, and maps for each province.
🔗 Repository Link: https://github.com/danishyarkhwork/afghanistan-provinces-districks-village-data
Key Features of the Dataset
The Afghanistan Provinces and Districts Data repository includes the following features:
-
Province-Level Data:
-
Each province includes information about its name, population, area in square kilometers, ethnic distribution, and the number of districts.
-
This structured data makes it easy to render on maps or convert into database tables for backend applications.
-
-
District-Level Data:
-
Each district entry includes its parent province, population data, area size, and village count.
-
This enables regional comparisons and allows for targeted research or app functionality.
-
-
Village-Level Data (Coming Soon):
-
One of the most anticipated updates is the addition of village-level data, which will further enhance the granularity of geographic insights.
-
This is particularly useful for NGOs, logistics companies, and governmental planning agencies working at the local level.
-
-
Province Maps:
-
Each province is associated with a detailed map stored in the repository’s /assets/maps directory.
-
This visual aid allows users to better understand geographic boundaries and relationships.
-
-
Structured JSON Format:
-
The dataset is available in JSON, which ensures ease of use in web applications, mobile apps, and APIs.
-
JSON format is widely compatible with modern programming languages such as JavaScript, Python, PHP, and more.
-
Who Can Benefit from This Data?
✔️ Developers:
If you’re building mobile apps, GIS-based tools, or dashboard interfaces that require Afghanistan administrative divisions, this data is ready for integration.
✔️ WordPress Plugin Creators:
WordPress developers can use this JSON data to create plugins that display Afghanistan’s provinces, districts, and future village data in a user-friendly format.
✔️ Researchers & Analysts:
Those working in academic or governmental fields can leverage this data to generate statistical reports or conduct spatial analysis.
✔️ NGOs & Aid Organizations:
Organizations delivering humanitarian aid in Afghanistan can benefit greatly from accurate regional data to plan their programs efficiently.
✔️ Students & Educators:
Educators can use this dataset to help students understand Afghanistan’s geography, population distribution, and administrative hierarchy.
Use Cases and Implementation Ideas
-
Interactive Maps: Use libraries like Leaflet or Mapbox to create a map interface that visualizes population and ethnic group distributions across provinces.
-
Mobile Apps: Build apps that display demographic information for travelers, aid workers, or researchers visiting different regions.
-
WordPress Geo Plugin: Create a plugin that allows website owners to showcase regional data of Afghanistan using shortcodes or widgets.
-
REST API Service: Convert the JSON files into a RESTful API to serve data to third-party platforms or services.
-
Local Government Dashboards: Use this data to build administrative dashboards to support policy-making or development planning.
Future Roadmap
The repository maintainer has outlined ambitious and meaningful future enhancements:
🔹 Village-Level Data:
Soon, each village in Afghanistan will be detailed with its name, associated district and province, population, and other relevant metrics.
🔹 REST API Development:
Plans are in motion to build a scalable API so external apps and platforms can pull the data programmatically and in real-time.
🔹 WordPress Plugin:
A dedicated plugin is on the horizon to help WordPress users display Afghan geographic data directly on their websites.
🔹 Interactive Visualization:
An interactive map interface is planned to help users explore Afghanistan’s geographic and demographic makeup intuitively.
Contribution and Licensing
This project is open to contributions. If you’re a developer or data analyst who wants to add more data or improve the existing structure, you are encouraged to fork the repository, make your changes, and submit a pull request. Make sure to adhere to the existing JSON format for consistency.

📜 License: The dataset is licensed under the MIT License, which allows for both personal and commercial use, provided that proper attribution is given.
How to Get Started
-
Visit the GitHub Repository: danishyarkhwork/afghanistan-provinces-districks-village-data
-
Clone or download the dataset.
-
Review the JSON structure and map assets in the respective folders.
-
Start integrating into your project—whether it’s an app, plugin, dashboard, or API.
Contact & Support
For questions, feature suggestions, or reporting issues, users can raise a GitHub issue or directly contact the maintainer. Collaboration is welcome, and contributions help keep the dataset accurate and up-to-date.
Final Thoughts
The Afghanistan Provinces, Districts, and Villages Data repository is a much-needed digital resource that promotes transparency, data accessibility, and technological development for Afghanistan. By providing this data in an open, structured format, the project empowers developers, researchers, and humanitarian workers to build impactful solutions rooted in accurate local information.
If you’re working on a project involving Afghan geography or planning data-driven development in the region, this GitHub repository is your go-to resource.
📍 Explore the dataset now: https://khaliddanishyar.com/afg-data/