Click tracking not working

Thank you for your reply! It is hosted on a live server. The link was embedded as a hyperlink, using the email builder.


1 Like

Bumping this once more. Still no solution found unfortunately.

@serty Which email provider are you using?

@Yosu_Cadilla We’re using locally hosted mail servers. We tried receiving the emails on several providers and they’re being received but there’s no luck with click tracking. The emails from the campaign are working just fine. Test emails are working,form-signup emails are working and so on. The issue arises only when click tracking is being used.

Bumping once again. Issue is still unresolved.

You’re using local email server for receiving or for sending or both?

Hi there everyone, we have the same issue.
Running a live instance on mautic 2.15.3 and php 7.2.24

Links in emails are getting re-written but actions are not being tracked.

We’ve tried both local and remote for receiving. Local for sending.

Sorry to hear you’re experiencing this too. If you find a solution, please let me know!

@serty @Omer Is any of you guys running Mautic behind a proxy (or cloudflare or other similar services)?

No, nothing like that. Issue is unfortunately still unresolved.

When hovering a link in your email, do you see your Mautic domain, or the final URL you are attempting to send people to?

I see my own domain with a click tracking attached to it:

@serty @alban

Did you guys solve the issue?
In my case, it was related to heathers and proxies, solved a while ago and been working like a charm since.
Please think twice before discarding proxies as a possible cause, proxies are everywhere nowadays.

Oh! and triple check your mtc.js is working as it is supposed to…

I have the same issue.
could you please explain better which was the issue?
My installation is behind a firewall that NATs the ip address

The issue is that Mautic needs to know the original IP from the visitor.
To confirm you have the same issue, tail your HTTP server logs and check if the real IPs are shown there or not.

There are a few ways to force passing that IP through proxies via heathers, I would suggest that you dig into the proxy protocol. Most services have implemented it (including AWS services) and it seems like the way to go, but there’s not much basic documentation around yet.

You need to implement it in all the layers your tracking data goes through, for example your bastion, LB, http server, etc.

In my case, there was a hidden (to me) proxy in LXC/LXD that I was unaware of.

1 Like


If using the free Cloudflare service (thus no access to the PROXY protocol), must I disable the “proxied” functionality of Cloudflare for the A record of the subdomain which points to the mautic install (on a VPS server) (e.g. And/or must I ALSO disable the “proxied” functionality of Cloudflare for the DNS A record of the MAIN site as well? (To have all click / tracking functionality working?) (e.g. ) … which means basically I lose all Cloudflare functionality without upgrading to their pro plan (to enable the PROXY protocol)?

I’m setting up Mautic for the first time now and just want to make sure everything is configured correctly.

Assuming you do not have any other proxy in the way…
You have 2 possibilities:

a) Disable all proxying in Cloudflare, which is very simple and straight forward. You can still use their DNS, you only loose the “anonymity” (which is easily circumvented if someone is targeting you anyways).
b) Enable proxy protocol on your Apache, which is kind of complicated and potentially troublesome if you aren’t a seasoned Linux Sys Admin.

In both cases, you do not need to pay unless you want to.

If you happen to be a good SysAdmin or if you are not but feel adventurous, here are 2 good starting points:

PD: Is not really that hard or complex, but the lack of documentation does not help the first time you try to achieve it, after that it’s easy as pie…

Let me know how it goes!

1 Like

Thank you @Yosu_Cadilla for your quick response.

I’ve just set up Mautic on Ubuntu 20.04 with an Nginx web server (instead of Apache) … and after browsing a few Cloudflare links (including one you posted above), I was left with the assumption that I must pay for Cloudflare’s “enterprise” (expensive) package in order to turn on Cloudflare’s “proxy protocol” feature… even if I did manage to set my Apache or Nginx web server to utilize the “proxy protocol”, doesn’t this mean Cloudflare doesn’t include the necessary header information to be deciphered unless they send it (e.g., paying for their “enterprise” feature which can turn on this setting?)

I did see an Nginx document (NGINX Docs | Accepting the PROXY Protocol) specifying how to set up the “proxy protocol” – but again, I’m assuming I’d still need Cloudflare’s “proxy protocol” setting to utilize it?

… unless of course I do not use Cloudflare at all … but I like that they serve my website up faster in various places so am trying my best to find a solution other than just turning off their proxying setting.

I have a fix for this for those that are using Send Grid - or another Email Gateway that uses Link Tracking. It is very important to turn OFF link tracking in Send Grid. It is enabled by default. Once I turned this off - all my links started to track properly :slight_smile: – It was adding something like “url483.” - that is a dead give away if you have something like that. Also a pro tip - When you are experimenting with link tracking for points - Make sure you open up those links in incognito mode - you can not properly test if you open from a browser while you have an active Mautic Session I think it is the cookie that spoils it.