{"id":20225685,"url":"https://github.com/d4v1-sudo/ip-geolocation-tool","last_synced_at":"2025-10-29T10:24:30.984Z","repository":{"id":223750512,"uuid":"761424886","full_name":"d4v1-sudo/IP-geolocation-tool","owner":"d4v1-sudo","description":"🖥️ → 🔎 → 🗺️ - Python code that utilizes the MaxMind GeoIP2 database to retrieve geolocation information for a given IP address.","archived":false,"fork":false,"pushed_at":"2024-09-05T01:02:15.000Z","size":36208,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-13T23:28:55.689Z","etag":null,"topics":["geoip","geoip-location","geoip2","geolocation","ip-geolocation","ip-lookup","latitude-and-longitude","latitude-longitude","maxmind","python"],"latest_commit_sha":null,"homepage":"https://dev.maxmind.com/static/pdf/GeoLite2-IP-MetaData-Databases-Comparison-Chart.pdf","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/d4v1-sudo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-21T21:01:31.000Z","updated_at":"2024-09-05T01:02:19.000Z","dependencies_parsed_at":"2024-07-07T12:06:15.031Z","dependency_job_id":null,"html_url":"https://github.com/d4v1-sudo/IP-geolocation-tool","commit_stats":null,"previous_names":["d4v1-sudo/ip-geolocation-tool"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/d4v1-sudo%2FIP-geolocation-tool","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/d4v1-sudo%2FIP-geolocation-tool/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/d4v1-sudo%2FIP-geolocation-tool/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/d4v1-sudo%2FIP-geolocation-tool/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/d4v1-sudo","download_url":"https://codeload.github.com/d4v1-sudo/IP-geolocation-tool/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241670128,"owners_count":20000325,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["geoip","geoip-location","geoip2","geolocation","ip-geolocation","ip-lookup","latitude-and-longitude","latitude-longitude","maxmind","python"],"created_at":"2024-11-14T07:14:20.304Z","updated_at":"2025-10-14T13:10:11.047Z","avatar_url":"https://github.com/d4v1-sudo.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## 🖥️ → 🔎 → 🗺️ - IP Geolocation Tool\n\nThis Python script utilizes the MaxMind GeoIP2 database to retrieve geolocation information for a given IP address.\n\n### Requirements\n- Python 3.x. [Install here](python.org)\n- MaxMind GeoLite2 City and ASN databases (`GeoLite2-City.mmdb`, `GeoLite2-ASN.mmdb`)\n\n### Usage\n1. Download\n    - Visit the GitHub repository page at [https://github.com/d4v1-sudo/IP-geolocation-tool](https://github.com/d4v1-sudo/IP-geolocation-tool.git).\n    - Click the \"Code\" button and select \"Download ZIP\" to download the repository as a ZIP file.\n    - Extract the contents of the ZIP file to your local machine.\n\n2. Run the script on terminal (linux) or cmd (windows)\n    ```python3 geo-ip.py```\n    or\n    ```python3 all.py```\n3. Enter the IP address you want to look up when prompted.\n\n### Output\nThe script will provide the following information if the IP address is found:\n- IP Address\n- AS Number\n- AS Name\n- ISP\n- City\n- Region\n- Country\n- Country Code\n- Postal Code\n- Timezone\n- Latitude\n- Longitude\n- Google Maps link to the location\n\n### Example\n```\nIP: 8.8.8.8\nIP Informations:\nIP Address: 8.8.8.8\nAS Number: 15169\nAS Name: Google LLC\nISP: Google LLC\nCity: Mountain View\nRegion: California\nCountry: United States\nCountry Code: US\nPostal Code: 94043\nTimezone: America/Los_Angeles\nLatitude: 37.4229\nLongitude: -122.085\nGoogle Maps: [Google Maps Link](https://www.google.com/maps/search/?api=1\u0026query=37.4229,-122.085)\n```\n\n### Note\n- If the IP address is not found in the database, the script will display a message indicating that the address was not found.\n\n### Dependencies\n- [geoip2](https://pypi.org/project/geoip2/) Python library, which can be installed via pip:\n\n```\npip install geoip2\n```\n### Download all MaxMind database for more data:\n\n[MaxMind GeoLite2 Database](https://github.com/P3TERX/GeoLite.mmdb)\n\n### Disclaimer\nThis script relies on third-party data provided by MaxMind. The accuracy of the geolocation information may vary.\n\n\u003ca href=\"https://visitorbadge.io/status?path=https%3A%2F%2Fgithub.com%2Fd4v1-sudo%2FIP-geolocation-tool\"\u003e\u003cimg src=\"https://api.visitorbadge.io/api/visitors?path=https%3A%2F%2Fgithub.com%2Fd4v1-sudo%2FIP-geolocation-tool\u0026label=Thanks%20for%20dropping%20in\u0026labelColor=%23000000\u0026countColor=%23FFFFFF\" /\u003e\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fd4v1-sudo%2Fip-geolocation-tool","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fd4v1-sudo%2Fip-geolocation-tool","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fd4v1-sudo%2Fip-geolocation-tool/lists"}