Deep links broken on custom domain

Deep links for an iOS and Android app are broken on a custom domain but work on the onrender.com project URL.

According to Google Playstore, the issue is that the link with the custom domain is redirecting with 301 status code, but the project onrender.com URL is okay because it does not redirect.

I opened a support ticket and the guy that responded said that the www.custom.xyz should precede custom.xyz in the “Custom Domain” section of the Render dashboard. However, he did not explain how to do that or why it matters.

So, how can I re-order them and why does the order matter? I tried deleting the custom domain and re-adding it, but it seems to be cached and just re-added itself in the same order. Both the www.custom.xyz and the custom.xyz URLs show up as green, verified, and state that a certificate has been issued.

When you add a domain on Render we would automatically setup another domain for you.

If you add custom.xyz first, then we presume that’s your canonical so we then setup www.custom.xyz as a redirect to custom.xyz.

The same vice-versa, if you setup www.custom.xyz first then we would add custom.xyz as a redirect to the www.

The only way to ‘invert’ the behavior is to delete the domain and re-add it ensuring you add the domain you want to use as the canonical first.

John, thank you for responding and the helpful explanation.

I have tried deleting and re-adding it in the correct order, but like I said, it seems to be cached. It just gets re-added as it was in the previous order. Is there an estimate for how long it should be deleted before re-added?

Once it’s down, there is nothing I can do for my users (right now there is just a message with a redirect link to the onrender.com project url).

Can you reach out directly from the ‘Contact Support’ link in the dashboard and I’ll pick you up there and we converse there - being able to check the domain myself would be most useful here.