The default server-side tagging deployment is hosted on an App Engine domain. We recommend that you modify the deployment to use a subdomain of your website instead.
Map a subdomain to your app
- In the Google Cloud Console, navigate to App Engine > Settings >
Custom Domains. Make sure you're in the project that matches your
- Click Add a custom domain.
If your domain is already verified, you may select it from the Select the domain you want to use section. Otherwise, select Verify a new domain from the drop-down menu.
If you haven’t verified your domain, do the following:
- Enter your subdomain (such as
metrics.example.com) and click Verify.
- After you click verify, a new Webmaster Central window will appear. Follow the steps as prompted in Webmaster Central to verify your ownership of your subdomain.
- After you complete the steps in Webmaster Central, close that window and return to the Add a new custom domain page in the Google Cloud Console. You may need to click Refresh domains to see your newly verified domain.
- Enter your subdomain (such as
In the Point your domain to [project-ID] section, remove the
When complete, click Save mappings.
Update DNS records at your domain registrar
After you've mapped your service to a custom domain in App Engine, update the DNS records at your domain registrar. As a convenience, App Engine generates and displays the DNS records you need to enter.
- To retrieve the DNS record information for your domain mappings, in Google Cloud Console, go to the Custom Domains tab of the App Engine Settings page. This page lists DNS records for all of the domains you have mapped to your app.
- Log in to your account at your domain registrar and open the DNS configuration page.
- Locate the host records section of your domain's configuration page and add
each of the DNS records that you retrieved when you mapped your domain to
your app. Enter the following information in the record fields:
- Record type: Enter the record type shown in the DNS record that Google created for you (A and AAAA).
- Record name: For A and AAAA records, enter the subdomain you registered. For example, enter "metrics" to map metrics.example.com.
- Data: Enter the record data (rrdata) that is shown in the DNS
record Google created for you. For A or AAAA records, the record data is
an IP address. If there is a CNAME record shown in addition to the A and
AAAA records, do not map the CNAME record.
Note: There are multiple IP addresses for the A or AAAA records. You should register multiple addresses to the same record, rather than creating separate records for each address.
- Save your changes in the DNS configuration page of your domain's account. In most cases, it takes only a few minutes for these changes to take effect, but in some cases it can take several hours. You can use dig to confirm the DNS records have been successfully updated.
- To test your subdomain, navigate to your server-side Tag Manager container
under Admin > Container Settings. and paste that URL into the Tagging
server URL. Click Save, navigate back to your workspace, then click
Preview. You should see the Debug panel pop up.
Note: It can take up to an hour for the automatic SSL certificate to be issued.