PHPackages                             palauaandsons/cloudflare-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. palauaandsons/cloudflare-geoip

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

palauaandsons/cloudflare-geoip
==============================

Cloudflare GeoIP helper with Laravel

1.2(2mo ago)14.5k↓33.3%MITPHP

Since May 15Pushed 2mo ago1 watchersCompare

[ Source](https://github.com/palauaandsons/cloudflare-geoip)[ Packagist](https://packagist.org/packages/palauaandsons/cloudflare-geoip)[ RSS](/packages/palauaandsons-cloudflare-geoip/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (5)Versions (6)Used By (0)

Cloudflare GeoIp for Laravel.
=============================

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

Get the geographical localtion of visitor based off Cloudflare headers.

Caution

Make sure [Visitor Location](https://developers.cloudflare.com/rules/transform/managed-transforms/reference/#add-visitor-location-headers) &amp; [IP Geolocation](https://developers.cloudflare.com/network/ip-geolocation/#add-ip-geolocation-information) are enabled in Cloudflare Dashboard.

### Installation

[](#installation)

```
composer require palauaandsons/cloudflare-geoip
```

#### Configuration

[](#configuration)

Run the following command to publish configuration. Be sure to modify the configuration file specifically the default location to use if the cloudflare headers are absent.

```
php artisan vendor:publish --tag=cloudflare-geoip-config
```

#### Usage

[](#usage)

```
