Skip to content

Provide Geolocation information to Matomo (Piwik) from Cloudflare request header

Notifications You must be signed in to change notification settings

angristan/matomo-cloudflare-location-provider

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Matomo Cloudflare Geolocation plugin

Description

Provides country-code geolocation for Matomo (Piwik) using Cloudflare headers. Use this instead of the default GeoIP2 plugin if all tracking requests are being routed through Cloudflare.

This plugin trusts the country code provided in the HTTP_CF_IPCOUNTRY header injected by Cloudflare, and does not require any GeoIP database. Ensure you enable IP Geolocation in the Cloudflare "Network" dashboard.

If requests are tracked outside of Cloudflare, no geolocation information will be available.

About

Provide Geolocation information to Matomo (Piwik) from Cloudflare request header

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%