|
| 1 | +--- |
| 2 | +title: Set up an Azure DNS zone for Azure Static Web Apps |
| 3 | +description: Create an Azure DNS zone for a custom domain in Azure Static Web Apps |
| 4 | +services: static-web-apps |
| 5 | +author: craigshoemaker |
| 6 | +ms.service: static-web-apps |
| 7 | +ms.topic: how-to |
| 8 | +ms.date: 02/14/2021 |
| 9 | +ms.author: cshoe |
| 10 | +--- |
| 11 | + |
| 12 | +# Set up an Azure DNS zone for Azure Static Web Apps |
| 13 | + |
| 14 | +By default, Azure Static Web Apps provides an auto-generated domain name for your website, but you can point a custom domain to your site. Free SSL/TLS certificates are automatically created for the auto-generated domain name and any custom domains you may add. |
| 15 | + |
| 16 | +This guide demonstrates how to configure your domain name with the `www` subdomain. Once this procedure is complete, you can set up an [apex domain](apex-domain-azure-dns.md). |
| 17 | + |
| 18 | +The following procedure requires you to copy settings from an Azure DNS zone you create and your existing static web app. Consider opening the Azure portal in two different windows to make it easier to switch between the two services. |
| 19 | + |
| 20 | +## Create an Azure DNS zone |
| 21 | + |
| 22 | +1. Log in to the [Azure portal](https://portal.azure.com). |
| 23 | + |
| 24 | +1. From the top search bar, enter **DNS zones**. |
| 25 | + |
| 26 | +1. Select **DNS zones**. |
| 27 | + |
| 28 | +1. Select the **Create** button. |
| 29 | + |
| 30 | +1. In the *Basics* tab, enter the following values. |
| 31 | + |
| 32 | + | Property | Value | |
| 33 | + |---|---| |
| 34 | + | Subscription | Select your Azure subscription. | |
| 35 | + | Resource group | Select to create a resource group. | |
| 36 | + | Name | Enter the domain name for this zone. | |
| 37 | + |
| 38 | +1. Select **Review + Create**. |
| 39 | + |
| 40 | +1. Select **Create** and wait for the zone to provision. |
| 41 | + |
| 42 | +1. Select **Go to resource**. |
| 43 | + |
| 44 | + With the DNS zone created, you now have access to Azure's DNS name servers for your application. |
| 45 | + |
| 46 | +1. From the *Overview* window, copy the values for **Name server 1** and **Name server 2** and set them aside in a text editor for later use. |
| 47 | + |
| 48 | +## Update name server addresses |
| 49 | + |
| 50 | +The next step is to update the name server addresses for your domain name. Sign in to your account on your domain provider's website and find the tools to edit your domain settings. While each domain provider is different, look for *Manage DNS*, *Domain settings*, or something similar in your domain account. |
| 51 | + |
| 52 | +1. With the name server addresses you collected from the previous step, update the name server addresses for your domain name. |
| 53 | + |
| 54 | +1. Save your changes. |
| 55 | + |
| 56 | +## Next steps |
| 57 | + |
| 58 | +> [!div class="nextstepaction"] |
| 59 | +> [Set up a custom domain in Azure DNS](custom-domain-azure-dns.md) |
0 commit comments