PHPackages                             ahmedzidan/geoip - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. ahmedzidan/geoip

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

ahmedzidan/geoip
================

Support for multiple GeoIP services.

1.0.7(7y ago)038BSD-2-ClausePHPPHP &gt;=5.5.9

Since Dec 12Pushed 7y ago1 watchersCompare

[ Source](https://github.com/ahmedfathi1/laravel-geoip)[ Packagist](https://packagist.org/packages/ahmedzidan/geoip)[ RSS](/packages/ahmedzidan-geoip/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (5)Versions (20)Used By (0)

GeoIP for Laravel 5
===================

[](#geoip-for-laravel-5)

[![Build Status](https://camo.githubusercontent.com/5f03ccd5af52165eec9ae09424812eb94a7253e457a833d77fff358348b364a2/68747470733a2f2f7472617669732d63692e6f72672f546f72616e6e2f6c61726176656c2d67656f69702e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/Torann/laravel-geoip)[![Latest Stable Version](https://camo.githubusercontent.com/b4c14a8e89fbb6b35a4ec178cffcdb93c48093b3e4d9cae15b1f1ef93baa9566/68747470733a2f2f706f7365722e707567782e6f72672f746f72616e6e2f67656f69702f762f737461626c652e706e67)](https://packagist.org/packages/torann/geoip)[![Total Downloads](https://camo.githubusercontent.com/b8537b5c4fa2664d4f542c6a974277ca0b9db5666d854a1346959c541f8b29d4/68747470733a2f2f706f7365722e707567782e6f72672f746f72616e6e2f67656f69702f646f776e6c6f6164732e706e67)](https://packagist.org/packages/torann/geoip)[![Patreon donate button](https://camo.githubusercontent.com/f9e075baad95563481d35174d43ef50757281abb6bc795d0f473fad452afa030/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f70617472656f6e2d646f6e6174652d79656c6c6f772e737667)](https://www.patreon.com/torann)[![Donate weekly to this project using Gratipay](https://camo.githubusercontent.com/0eeae019980adaa1dc64842cfb01f3d738c688982ea4eb58094047011cb46704/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f67726174697061792d646f6e6174652d79656c6c6f772e737667)](https://gratipay.com/~torann)[![Donate to this project using Flattr](https://camo.githubusercontent.com/d79e412f78041f87e203449041ad81848a8405cf0f3c622c51e3bad0c2a4b599/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f666c617474722d646f6e6174652d79656c6c6f772e737667)](https://flattr.com/profile/torann)[![Donate to this project using Paypal](https://camo.githubusercontent.com/604e3db9c8751116b3f765aad0353ec7ded655bbe8aaacbc38d8c4a6b784b3ed/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f446f6e6174652d50617950616c2d677265656e2e737667)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=4CJA2A97NPYVU)

Determine the geographical location and currency of website visitors based on their IP addresses.

- [GeoIP for Laravel 5 on Packagist](https://packagist.org/packages/torann/geoip)
- [GeoIP for Laravel 5 on GitHub](https://github.com/Torann/laravel-geoip)
- [Upgrade Guides](http://lyften.com/projects/laravel-geoip/doc/upgrade.html)

Official Documentation
----------------------

[](#official-documentation)

Documentation for the package can be found on [Lyften.com](http://lyften.com/projects/laravel-geoip/).

Laravel 5
---------

[](#laravel-5)

### Install

[](#install)

- composer require ahmedzidan/geoip

Laravel 4
---------

[](#laravel-4)

For Laravel 4 Installation see [version 0.1.1](https://github.com/Torann/laravel-geoip/tree/0.1.1)

Change Log
----------

[](#change-log)

#### v1.0.2

[](#v102)

- Support double IP addresses #25

#### v1.0.1

[](#v101)

- Fix bug #60

#### v1.0.0

[](#v100)

- Major code refactoring and cleanup
- Add currency support
- Add Location object
- Add cache drivers
- Add `state_name` to `$location` array #46
- Set locales in config #45
- Raise PHP requirement to 5.5
- Fix file structure to adher to PSR-4 file structure. #40
- Support custom Geo IP services
    - Added ip-api.com service (Thanks to [nikkiii](https://github.com/nikkiii))

#### v0.2.1

[](#v021)

- Add database\_path to config
- Add update\_url to config
- Add GeoIP database update command "php artisan geoip:update"
- Add some test
- Format code

#### v0.2.0

[](#v020)

- Update to Laravel 5
- Support IPv6
- Log address not found exceptions
- Supports a custom default location

Contributions
-------------

[](#contributions)

Many people have contributed to project since its inception.

Thanks to:

- [nikkiii](https://github.com/nikkiii)
- [jeffhennis](https://github.com/jeffhennis)
- [max-kovpak](https://github.com/max-kovpak)
- [dotpack](https://github.com/dotpack)

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community17

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 69.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~100 days

Recently: every ~122 days

Total

18

Last Release

2872d ago

Major Versions

0.2.3 → 1.0.x-dev2016-10-02

0.2.4 → 1.0.32017-01-26

0.2.x-dev → 1.0.42017-06-21

PHP version history (2 changes)0.1.0PHP &gt;=5.3.0

1.0.x-devPHP &gt;=5.5.9

### Community

Maintainers

![](https://www.gravatar.com/avatar/2565fae9720ee446b57d1bcc550ceb31f1d223448b6bffd9670eedf1d964e079?d=identicon)[ahmedzidan](/maintainers/ahmedzidan)

---

Top Contributors

[![Torann](https://avatars.githubusercontent.com/u/1406755?v=4)](https://github.com/Torann "Torann (72 commits)")[![dotpack](https://avatars.githubusercontent.com/u/1175814?v=4)](https://github.com/dotpack "dotpack (10 commits)")[![AFZidan](https://avatars.githubusercontent.com/u/4643935?v=4)](https://github.com/AFZidan "AFZidan (4 commits)")[![kyranb](https://avatars.githubusercontent.com/u/5426926?v=4)](https://github.com/kyranb "kyranb (3 commits)")[![osmhub](https://avatars.githubusercontent.com/u/13149318?v=4)](https://github.com/osmhub "osmhub (3 commits)")[![Butochnikov](https://avatars.githubusercontent.com/u/4212297?v=4)](https://github.com/Butochnikov "Butochnikov (2 commits)")[![LukeT](https://avatars.githubusercontent.com/u/2203091?v=4)](https://github.com/LukeT "LukeT (2 commits)")[![rjp2525](https://avatars.githubusercontent.com/u/1334865?v=4)](https://github.com/rjp2525 "rjp2525 (2 commits)")[![sakalauskas](https://avatars.githubusercontent.com/u/1455148?v=4)](https://github.com/sakalauskas "sakalauskas (1 commits)")[![Omranic](https://avatars.githubusercontent.com/u/406705?v=4)](https://github.com/Omranic "Omranic (1 commits)")[![evaldas-leliuga](https://avatars.githubusercontent.com/u/1867113?v=4)](https://github.com/evaldas-leliuga "evaldas-leliuga (1 commits)")[![Dylan-DPC](https://avatars.githubusercontent.com/u/99973273?v=4)](https://github.com/Dylan-DPC "Dylan-DPC (1 commits)")[![irtaza100](https://avatars.githubusercontent.com/u/34660777?v=4)](https://github.com/irtaza100 "irtaza100 (1 commits)")[![hughsaffar](https://avatars.githubusercontent.com/u/10440022?v=4)](https://github.com/hughsaffar "hughsaffar (1 commits)")

---

Tags

laravelgeoipgeolocationmaxmindlaravel 5locationIP APIinfoDB

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ahmedzidan-geoip/health.svg)

```
[![Health](https://phpackages.com/badges/ahmedzidan-geoip/health.svg)](https://phpackages.com/packages/ahmedzidan-geoip)
```

###  Alternatives

[torann/geoip

Support for multiple Geographical Location services.

2.2k14.9M92](/packages/torann-geoip)[interaction-design-foundation/laravel-geoip

Support for multiple Geographical Location services.

19253.0k3](/packages/interaction-design-foundation-laravel-geoip)[laravel/ai

The official AI SDK for Laravel.

9782.1M162](/packages/laravel-ai)[pulkitjalan/ip-geolocation

IP Geolocation Wrapper with Laravel Support

91194.7k1](/packages/pulkitjalan-ip-geolocation)[zidbih/laravel-deadlock

Make temporary Laravel workarounds expire and fail CI when ignored.

984.0k](/packages/zidbih-laravel-deadlock)[tomshaw/electricgrid

A feature-rich Livewire package designed for projects that require dynamic, interactive data tables.

119.2k](/packages/tomshaw-electricgrid)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
