You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -89,6 +89,12 @@ When you see the following notification, the scale operation is complete.
89
89
90
90
<aname="cname"aria-hidden="true"></a>
91
91
92
+
## Get domain verification ID
93
+
94
+
To add a custom domain to your app, you need to verify your ownership of the domain by adding a verification ID as a TXT record with your domain provider. In the left navigation of your app page, click **Resource explorer** under **Development Tools**, then click **Go**.
95
+
96
+
In the JSON view of your app's properties, search for `customDomainVerificationId`, and copy its value inside the double quotes. You need this verification ID for the next step.
97
+
92
98
## Map your domain
93
99
94
100
You can use either a **CNAME record** or an **A record** to map a custom DNS name to App Service. Follow the respective steps:
@@ -110,11 +116,14 @@ In the tutorial example, you add a CNAME record for the `www` subdomain (for exa
110
116
111
117
#### Create the CNAME record
112
118
113
-
Add a CNAME record to map a subdomain to the app's default domain name (`<app_name>.azurewebsites.net`, where `<app_name>` is the name of your app).
119
+
Map a subdomain to the app's default domain name (`<app_name>.azurewebsites.net`, where `<app_name>` is the name of your app). To create a CNAME mapping for the `www` subdomain, create two records:
114
120
115
-
For the `www.contoso.com` domain example, add a CNAME record that maps the name `www` to `<app_name>.azurewebsites.net`.
121
+
| Record type | Host | Value | Comments |
122
+
| - | - | - |
123
+
| CNAME |`www`|`<app_name>.azurewebsites.net`| The domain mapping itself. |
124
+
| TXT |`asuid.www`|[The verification ID you got earlier](#get-domain-verification-id)| App Service accesses the `asuid.<subdomain>` TXT record to verify your ownership of the custom domain. |
116
125
117
-
After you add the CNAME, the DNS records page looks like the following example:
126
+
After you add the CNAME and TXT records, the DNS records page looks like the following example:
118
127
119
128

120
129
@@ -179,25 +188,20 @@ In the **Custom domains** page, copy the app's IP address.
179
188
180
189
#### Create the A record
181
190
182
-
To map an A record to an app, App Service requires **two** DNS records:
191
+
To map an A record to an app, usually to the root domain, create two records:
183
192
184
-
- An **A** record to map to the app's IP address.
185
-
- A **TXT** record to map to the app's default domain name `<app_name>.azurewebsites.net`. App Service uses this record only at configuration time, to verify that you own the custom domain. After your custom domain is validated and configured in App Service, you can delete this TXT record.
186
-
187
-
For the `contoso.com` domain example, create the A and TXT records according to the following table (`@` typically represents the root domain).
188
-
189
-
| Record type | Host | Value |
193
+
| Record type | Host | Value | Comments |
190
194
| - | - | - |
191
-
| A |`@`| IP address from [Copy the app's IP address](#info)|
192
-
| TXT |`@`|`<app_name>.azurewebsites.net`|
195
+
| A |`@`| IP address from [Copy the app's IP address](#info)| The domain mapping itself (`@` typically represents the root domain). |
196
+
| TXT |`asuid`|[The verification ID you got earlier](#get-domain-verification-id)| App Service accesses the `asuid.<subdomain>` TXT record to verify your ownership of the custom domain. For the root domain, use `asuid`.|
193
197
194
198
> [!NOTE]
195
199
> To add a subdomain (like `www.contoso.com`) using an A record instead of a recommended [CNAME record](#map-a-cname-record), your A record and TXT record should look like the following table instead:
196
200
>
197
201
> | Record type | Host | Value |
198
202
> | - | - | - |
199
203
> | A |`www`| IP address from [Copy the app's IP address](#info)|
When the records are added, the DNS records page looks like the following example:
@@ -253,6 +257,11 @@ Add a CNAME record to map a wildcard name to the app's default domain name (`<ap
253
257
254
258
For the `*.contoso.com` domain example, the CNAME record will map the name `*` to `<app_name>.azurewebsites.net`.
255
259
260
+
| Record type | Host | Value | Comments |
261
+
| - | - | - |
262
+
| CNAME |`*`|`<app_name>.azurewebsites.net`| The domain mapping itself. |
263
+
| TXT |`asuid.<subdomain>`|[The verification ID you got earlier](#get-domain-verification-id)| App Service accesses the `asuid.<subdomain>` TXT record to verify your ownership of the custom domain. |
264
+
256
265
When the CNAME is added, the DNS records page looks like the following example:
257
266
258
267

0 commit comments