Cloudflare, Apache 2.4 and mod_remoteip

I have a website behind Cloudflare.
Apache is configured with mod_remoteip so that the correct IP’s are in the log files.
As per the following documentation, setting mod_remoteip up is enough for Matomo to view real IP’s but users still are presented with Cloudflare IP’s.
Did I miss something ?

If you use Apache 2.4 or Apache 2.5, there is an alternative solution, you could use mod_remoteip to override the client IP with the IP as provided by a proxy or load balancer. Then you won’t need to specify these Matomo config settings.


Honestly I have no idea how the setup with Cloudflare works, but maybe this third-party plugin might help:
(But I think it just takes the geolocation, not the IP from the headers)

Dod you also set proxy_client_headers[] = HTTP_CF_CONNECTING_IP as explained in the linked guide?

Thanks Lukas, that works.
I was confused ny the note saying it is an “alternative solution”.