Doc: Add a custom domain to a branch. Not working.

Link: https://developers.cloudflare.com/pages/how-to/custom-branch-aliases/ When I find CNAME record with the name staging and change the target to include your branch alias. (mydomain.com -> staging.mydomain.com) I get redirect to : https://staging.mydomain.com/cdn-cgi/access/authorized?nonce=xxx….. May I ask for help..
Add a custom domain to a branch · Cloudflare Pages docs
In this guide, you will learn how to add a custom domain (staging.example.com) that will point to a specific branch (staging) on your Pages project.
2 Replies
junx
junx11mo ago
Update: Resolved I add the two application domains at “Cloudflare ZeroTrust Access”. Ref: https://community.cloudflare.com/t/error-404-with-custom-domain-using-cloudflare-zerotrust-access/417828
Cloudflare Community
Error 404 with custom domain using Cloudflare ZeroTrust Access
I’m using “Cloudflare Pages” and I set up a custom domain, all ok. However, after I activated the “Cloudflare ZeroTrust Access”, after logging in, the redirection is made to “{domain}/cdn-cgi/access/authorized?nonce={token}”, and the 404 error occurs in the custom domain . In {domain}.pages.dev “Cloudflare ZeroTrust Access” works correctly, th...
junx
junx11mo ago