Share via

Azure Front Door custom domain with Power Pages causing ExternalAuthenticationFailed during Azure AD login

Sumayyah Shamsudeen 0 Reputation points
2026-03-08T19:07:48.7733333+00:00

I am trying to configure a custom subdomain for a Power Pages website using Azure Front Door as the entry point. The DNS is managed externally.

Setup

  • Power Pages site has the default URL: *.powerappsportals.com
  • A custom subdomain is configured to access the portal through Azure Front Door.
  • Azure Front Door uses the Power Pages URL as the origin.
  • Front Door managed TLS certificate is enabled for the custom domain.

Configuration Completed

  1. Created Azure Front Door profile.
  2. Added the Power Pages default domain as the origin.
  3. Configured origin group and routing rules.
  4. Added the custom domain in Azure Front Door.
  5. Verified domain ownership using the TXT record provided by Azure.
  6. Added the TXT record in the DNS provider.
  7. Added a CNAME record pointing the subdomain to the Front Door endpoint.
  8. Enabled Front Door managed TLS certificate.
  9. Verified DNS resolution using nslookup, the subdomain correctly resolves to the Front Door endpoint.
  10. Added the custom domain redirect URIs in Azure App Registration.

Issue

When accessing the custom subdomain:

1.The request successfully routes through Azure Front Door.
2.The portal loads and immediately redirects to Microsoft Entra ID for login.
3.Authentication fails with: ExternalAuthenticationFailed

When inspecting the login request to Microsoft Entra ID, the redirect_uri parameter still points to the default Power Pages domain instead of the custom subdomain.

Example:

redirect_uri = https://

Azure Front Door
Azure Front Door

An Azure service that provides a cloud content delivery network with threat protection.


1 answer

Sort by: Most helpful
  1. AI answer

    2026-03-08T19:08:05.5133333+00:00

    Yes. The custom domain must also be configured directly on the Power Pages site, not only on Azure Front Door and in DNS.

    Power Pages generates its authentication URLs (including redirect_uri) based on the site’s configured host name. If the site only knows about the default *.powerappsportals.com domain, it will continue to use that in the Entra ID redirect, even when requests arrive through Azure Front Door.

    To fix the ExternalAuthenticationFailed and ensure redirect_uri uses the custom subdomain:

    1. Configure the custom domain on the Power Pages site itself (Connect/Add Custom Domain) so that the site recognizes the custom host name as valid for the portal.
    2. Then follow the documented pattern for Azure Front Door with Power Pages:
      • Use the Power Pages default domain as the origin host name in Front Door.
      • After the custom domain is added to Power Pages, update DNS so the CNAME for the custom domain points to the Azure Front Door endpoint (not directly to Power Pages).
      • Configure the same custom domain on the Azure Front Door endpoint and complete domain validation / TLS.
    3. Confirm with nslookup that the custom domain’s CNAME now points to the Front Door endpoint and that browsing the custom domain shows the Power Pages site.

    This sequence ensures that:

    • Power Pages accepts the custom domain and sets cookies and authentication URLs for it.
    • Azure Front Door fronts that custom domain and forwards traffic to the Power Pages origin.

    Without adding the custom domain in Power Pages, the portal continues to use the default domain in the Entra ID redirect, which leads to the ExternalAuthenticationFailed behavior described.


    References:

    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.