Domain CNAME pointing to Zero trust tunnel gives error: This site can’t provide a secure connection

Hello,
I am trying to redirect a domain to my Cloudflare tunnel's domain via a CNAME record.

I have a Zero Trust tunnel running on localhost. On a different domain I added a CNAME record that point to my tunnel's URL, but when I try to access it I get the error: This site can’t provide a secure connection error.

The situation: my localhost is accessible trough sub.example.com and it works fine. other.domain.com points to sub.example.com. Accessing other.domain.com should redirect me to sub.example.com (where my localhost is).
I have an Universal SSL certificate on the domain and the SSL/TLS encryption mode is Full (strict).

Summarized:

Accessing sub.example.com works fine. This is the domain configured on Cloudflare.
Another domain other.domain.com points to sub.example.com, but it gives the mentioned error.

Both domains are purchased from Namecheap, but and the main one uses Cloudflare's nameservers.


I would really appreciate any help, because at this point I have no idea what is causing this to happen.
I believe it has something to do with the SSL certificate, but I have a Universal SLL certificate on the whole domain and its subdomains
image.png
Was this page helpful?