WP Statistics not working with wp rocket
-
Hey there,
since I activated wp rocket on my wordpress site the numbers of “unique visitors” dropped to 1/4. the number of hits are still ok.I think the reason is quite simple. My nginx logs the following:
98.254.xxx.xxx – – [08/Mar/2021:18:41:54 +0100] “GET /wp-json/wp-statistics/v2/hit?_=1615219811&_wpnonce=f7040307&wp_statistics_hit_rest=yes&browser=Unbekannter&platform=Unbekannte&version=Unbekannte&referred=https://seatable.io/&ip=46.163.117.xxx&exclusion_match=yes&exclusion_reason=CrawlerDetect&ua=WP%20Rocket/Preload&track_all=1×tamp=1615223411¤t_page_type=home¤t_page_id=2&search_query&page_uri=/&user_id=0 HTTP/2.0″ 200 85 “https://seatable.io/” “Mozilla/5.0 (Macintosh; Intel Mac OS X 11_2_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.192 Safari/537.36”
The problem is that the server ip is passed with the parameter ?ip=… Therefore wp statistics counts these users not as unique visitors but as hits.
cache plugin is enabled in the settings and I saved already the permalinks in wordpress. Any tipps how to tell wp statistics to use the “real ip” and not this autogenerated by wp rocket?
Thanks and best regards
ChristophThe page I need help with: [log in to see the link]
The topic ‘WP Statistics not working with wp rocket’ is closed to new replies.