Azure Static Web App Subdomain Redirection

Jason Graves 61 Reputation points
2021-06-22T23:57:01.65+00:00

Hello!

I have created an Azure Static Web App and added custom domain. The custom domain is an apex domain or root domain via CNAME Flattening within the DNS. I would like to configure the subdomain www to redirect to the root domain. Is this possible via Azure Static Web App? What about in combination with another Azure service?

Azure Static Web Apps
Azure Static Web Apps
An Azure service that provides streamlined full-stack web app development.
762 questions
{count} votes

Accepted answer
  1. Grmacjon-MSFT 16,011 Reputation points
    2021-06-29T15:23:43.827+00:00

    Hi @Jason Graves

    Thanks for your patience. I confirmed with the engineering team that your scenario is currently not supported for Azure static web app. however, The engineering team is currently working on a feature that would support Azure Static Web App Subdomain redirection which will hopefully be released in the next few months.

    Best,
    Grace


1 additional answer

Sort by: Most helpful
  1. rook1e 5 Reputation points
    2023-03-24T04:26:11.66+00:00

    Add apex and www domains in "Custom Domains", then set apex as the default domain.

    Quoted from the documentation:

    When you designate a custom domain as your app's default domain, requests to other domains are automatically redirected to the default domain. Only one custom domain can be set as the default.

    1 person found this answer helpful.
    0 comments No comments