Piwik not working with CloudFlare?

Hey guys,

I have a server running CentOS 7 - I have successfully installed Piwik and when I embed the stats script into a page I want to track it doesn’t appear to be working.

I can confirm the following:

[li] The script tag shows when viewing source of page to be tracked
[/li][li] https is enabled on both the piwik site and the site to be tracked
[/li][li] I am using CloudFlare DNS and SSL
[/li][li] I have mod_cloudflare installed and included in apache (to pass through real IP to server)

No matter how many times I refresh the page to be tracked it still shows the “No data has been recorded yet” message.

Any help would be greatly appreciated!

BUMP - any help would be greatly appreciated!


please see CloudFlare FAQ: How to configure Piwik for use with Cloudflare – Cloudflare Support

and Piwik FAQ: How do I configure Piwik when the server is installed behind a proxy? - Analytics Platform - Matomo

I don’t want to create yet another thread, so will bump this one.

I have a self hosted instance of Matomo, and a wordpress website both on shared hosting, everything was working fine until I started to use Cloudflare. I have seen the article suggesting I get my hosting provider to install mod_cloudflare, but QQ is this on the wordpress server or the Matomo server, or do I need it on both?

As I am at the whim of my hosting provider is there a plan B for those that cannot have this module installed?

I’d like to follow-up, too, with using Matomo behind CloudFlare. Does CloudFlare’s cache interfere with getting page view information? I am using both Matomo and Google Analytics, and the numbers are finally approaching similarity - about 5% - 10% difference, and sometimes in opposite directions. BUT - if CloudFlare’s cache isn’t hitting my server - not sure if I’d hear about it?

And, yes, I do have the PHP mod for CloudFlare, though I don’t recall it making a difference…