|
| 1 | +--- |
| 2 | +title: Configure DNS names with Traffic Manager |
| 3 | +description: Learn how to configure a custom domain for an Azure App Service app that integrates with Traffic Manager for load balancing. |
| 4 | +ms.assetid: 0f96c0e7-0901-489b-a95a-e3b66ca0a1c2 |
| 5 | +ms.topic: article |
| 6 | +ms.date: 03/05/2020 |
| 7 | +ms.custom: seodec18 |
| 8 | + |
| 9 | +--- |
| 10 | +# Configure a custom domain name in Azure App Service with Traffic Manager integration |
| 11 | + |
| 12 | +[!INCLUDE [web-selector](../../includes/websites-custom-domain-selector.md)] |
| 13 | + |
| 14 | +> [!NOTE] |
| 15 | +> For Cloud Services, see |
| 16 | +[Configuring a custom domain name for an Azure cloud service](../cloud-services/cloud-services-custom-domain-name.md). |
| 17 | + |
| 18 | +When you use [Azure Traffic Manager](/azure/traffic-manager/) to load balance traffic to [Azure App Service](overview.md), the App Service app can be accessed using **\<traffic-manager-endpoint>.trafficmanager.net**. You can assign a custom domain name, such as www\.contoso.com, with your App Service app in order to provide a more recognizable domain name for your users. |
| 19 | + |
| 20 | +This article shows you how to configure a custom domain name with an App Service app that's integrated with [Traffic Manager](../traffic-manager/traffic-manager-overview.md). |
| 21 | + |
| 22 | +> [!NOTE] |
| 23 | +> Only [CNAME](https://en.wikipedia.org/wiki/CNAME_record) records are supported when you configure a domain name using the Traffic Manager endpoint. Because A records are not supported, a root domain mapping, such as contoso.com is also not supported. |
| 24 | +> |
| 25 | +
|
| 26 | +## Prepare the app |
| 27 | + |
| 28 | +To map a custom DNS name to an app that's integrated with Azure Traffic Manager, the web app's [App Service plan](https://azure.microsoft.com/pricing/details/app-service/) must be in **Standard** tier or higher. In this step, you make sure that the App Service app is in the supported pricing tier. |
| 29 | + |
| 30 | +### Check the pricing tier |
| 31 | + |
| 32 | +In the [Azure portal](https://portal.azure.com), search for and select **App Services**. |
| 33 | + |
| 34 | +On the **App Services** page, select the name of your Azure app. |
| 35 | + |
| 36 | + |
| 37 | + |
| 38 | +In the left navigation of the app page, select **Scale up (App Service plan)**. |
| 39 | + |
| 40 | + |
| 41 | + |
| 42 | +The app's current tier is highlighted by a blue border. Check to make sure that the app is in **Standard** tier or above (any tier in the **Production** or **Isolated** category). If yes, close the **Scale up** page and skip to [Create the CNAME mapping](#create-the-cname-mapping). |
| 43 | + |
| 44 | + |
| 45 | + |
| 46 | +### Scale up the App Service plan |
| 47 | + |
| 48 | +If you need to scale up your app, select any of the pricing tiers in the **Production** category. For additional options, click **See additional options**. |
| 49 | + |
| 50 | +Click **Apply**. |
| 51 | + |
| 52 | +## Create Traffic Manager endpoint |
| 53 | + |
| 54 | +Following the steps at [Add or Delete Endpoints](../traffic-manager/traffic-manager-endpoints.md), add your App Service app as an endpoint in your Traffic Manager profile. |
| 55 | + |
| 56 | +Once your App Service app is in a supported pricing tier, it shows up in the list of available App Service targets when you add the endpoint. If your app isn't listed, [verify the pricing tier of your app](#prepare-the-app). |
| 57 | + |
| 58 | +## Create the CNAME mapping |
| 59 | +> [!NOTE] |
| 60 | +> To configure an [App Service domain that you purchased](manage-custom-dns-buy-domain.md), skip this section and go to [Enable custom domain](#enable-custom-domain). |
| 61 | +> |
| 62 | +
|
| 63 | +[!INCLUDE [Access DNS records with domain provider](../../includes/app-service-web-access-dns-records-no-h.md)] |
| 64 | + |
| 65 | +While the specifics of each domain provider vary, you map *from* the custom domain name (such as **contoso.com**) *to* the Traffic Manager domain name (**contoso.trafficmanager.net**) that's integrated with your app. |
| 66 | + |
| 67 | +> [!NOTE] |
| 68 | +> If a record is already in use and you need to preemptively bind your apps to it, you can create an additional CNAME record. For example, to preemptively bind **www\.contoso.com** to your app, create a CNAME record from **awverify.www** to **contoso.trafficmanager.net**. You can then add "www\.contoso.com" to your app without the need to change the "www" CNAME record. For more information, see [Migrate an active DNS name to Azure App Service](manage-custom-dns-migrate-domain.md). |
| 69 | +
|
| 70 | +Once you have finished adding or modifying DNS records at your domain provider, save the changes. |
| 71 | + |
| 72 | +## Enable custom domain |
| 73 | +After the records for your domain name have propagated, use the browser to verify that your custom domain name resolves to your App Service app. |
| 74 | + |
| 75 | +> [!NOTE] |
| 76 | +> It can take some time for your CNAME to propagate through the DNS system. You can use a service such as <a href="https://www.digwebinterface.com/">https://www.digwebinterface.com/</a> to verify that the CNAME is available. |
| 77 | +> |
| 78 | +> |
| 79 | +
|
| 80 | +1. Once domain resolution succeeds, to back to your app page in the [Azure Portal](https://portal.azure.com) |
| 81 | +2. From the left navigation, select **Custom domains** > **Add hostname**. |
| 82 | +4. Type the custom domain name that you mapped earlier and select **Validate**. |
| 83 | +5. Make sure that **Hostname record type** is set to **CNAME (www\.example.com or any subdomain)**. |
| 84 | + |
| 85 | +6. Since the App Service app is now integrated with a Traffic Manager endpoint, you should see the Traffic Manager domain name under **CNAME configuration**. Select it and click **Add custom domain**. |
| 86 | + |
| 87 | +  |
| 88 | + |
| 89 | +## Next steps |
| 90 | + |
| 91 | +> [!div class="nextstepaction"] |
| 92 | +> [Secure a custom DNS name with an SSL binding in Azure App Service](configure-ssl-bindings.md) |
0 commit comments