<!DOCTYPE html>
<html>
<head>
    <link href="css/awsdocs.css" rel="stylesheet" type="text/css">
    <script type="text/javascript" src="js/jquery.min.js"></script>
    <script type="text/javascript" src="js/awsdocs.min.js"></script>
    <meta charset="utf-8">
</head>
<body>
    <div id="content" style="padding: 10px 30px;">
    <h1 class="topictitle" id="aws-resource-route53-hostedzone">AWS::Route53::HostedZone</h1><p>The <code class="code">AWS::Route53::HostedZone</code> resource creates a hosted zone, which can contain
                        a collection of record sets for a domain. You cannot create a hosted zone for a top-level
                        domain (TLD). For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_CreateHostedZone.html">POST CreateHostedZone</a> or <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API-create-hosted-zone-private.html">POST CreateHostedZone
                           (Private)</a> in the <em>Amazon Route&#xA0;53 API Reference</em>.
                     </p><h2 id="aws-resource-route53-hostedzone-syntax">Syntax</h2><p>To declare this entity in your AWS CloudFormation template, use the following syntax:</p><div id="JSON" name="JSON" class="section langfilter">
                        <h3 id="aws-resource-route53-hostedzone-syntax.json">JSON</h3>
                        
                        <pre class="programlisting"><div class="code-btn-container"><div class="btn-copy-code" title="Copy"></div><div class="btn-dark-theme" title="Dark theme" title-dark="Dark theme" title-light="Light theme"></div></div><code class="nohighlight">{
  &quot;Type&quot; : &quot;AWS::Route53::HostedZone&quot;,
  &quot;Properties&quot; : {
    &quot;<a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-hostedzoneconfig">HostedZoneConfig</a>&quot; : <a href="aws-properties-route53-hostedzone-hostedzoneconfig.html">HostedZoneConfig</a>,
    &quot;<a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-hostedzonetags">HostedZoneTags</a>&quot; : [ <a href="aws-properties-route53-hostedzone-hostedzonetags.html">HostedZoneTags</a>, ... ],
    &quot;<a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-name">Name</a>&quot; : <em class="replaceable"><code>String</code></em>,
    &quot;<a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-queryloggingconfig">QueryLoggingConfig</a>&quot; : <a href="aws-properties-route53-hostedzone-queryloggingconfig.html">QueryLoggingConfig</a>,
    &quot;<a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-vpcs">VPCs</a>&quot; : [ <a href="aws-resource-route53-hostedzone-hostedzonevpcs.html">HostedZoneVPCs</a>, ... ]
  }
}</code></pre>
                        </div><div id="YAML" name="YAML" class="section langfilter">
                        <h3 id="aws-resource-route53-hostedzone-syntax.yaml">YAML</h3>
                        
                        <pre class="programlisting"><div class="code-btn-container"><div class="btn-copy-code" title="Copy"></div><div class="btn-dark-theme" title="Dark theme" title-dark="Dark theme" title-light="Light theme"></div></div><code class="nohighlight">Type: &quot;AWS::Route53::HostedZone&quot;
Properties: 
  <a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-hostedzoneconfig">HostedZoneConfig</a>:
    <a href="aws-properties-route53-hostedzone-hostedzoneconfig.html">HostedZoneConfig</a>
  <a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-hostedzonetags">HostedZoneTags</a>:
    - <a href="aws-properties-route53-hostedzone-hostedzonetags.html">HostedZoneTags</a>
  <a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-name">Name</a>: <em class="replaceable"><code>String</code></em>
  <a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-queryloggingconfig">QueryLoggingConfig</a>: 
    <a href="aws-properties-route53-hostedzone-queryloggingconfig.html">QueryLoggingConfig</a>
  <a href="aws-resource-route53-hostedzone.html#cfn-route53-hostedzone-vpcs">VPCs</a>:
    - <a href="aws-resource-route53-hostedzone-hostedzonevpcs.html">HostedZoneVPCs</a> 
</code></pre>
                        </div><h2 id="w2ab1c21c10d201c18b7">Properties</h2><div class="variablelist">
                        
                        
                        
                        
                        
                        
                        <dl>
                           
                           <dt><a id="cfn-route53-hostedzone-hostedzoneconfig"></a><span class="term"><code class="code">HostedZoneConfig</code></span></dt>
                           
                           <dd>
                              
                              <p>A complex type that contains an optional comment about your hosted zone.</p>
                              
                              <p><em>Required</em>: No
                              </p>
                              
                              <p><em>Type</em>: <a href="aws-properties-route53-hostedzone-hostedzoneconfig.html">Route&#xA0;53 HostedZoneConfig Property</a></p>
                              
                              <p><em>Update requires</em>: <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt">No interruption</a></p>
                              
                           </dd>
                           
                           
                           <dt><a id="cfn-route53-hostedzone-hostedzonetags"></a><span class="term"><code class="code">HostedZoneTags</code></span></dt>
                           
                           <dd>
                              
                              <p>An arbitrary set of tags (key&#x2013;value pairs) for this hosted zone.</p>
                              
                              <p><em>Required</em>: No
                              </p>
                              
                              <p><em>Type</em>: List of <a href="aws-properties-route53-hostedzone-hostedzonetags.html">Amazon Route&#xA0;53 HostedZoneTags</a></p>
                              
                              <p><em>Update requires</em>: <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt">No interruption</a></p>
                              
                           </dd>
                           
                           
                           <dt><a id="cfn-route53-hostedzone-name"></a><span class="term"><code class="code">Name</code></span></dt>
                           
                           <dd>
                              
                              <p>The name of the domain. For resource record types that include a domain name,
                                 specify a fully qualified domain name.
                              </p>
                              
                              <p><em>Required</em>: Yes
                              </p>
                              
                              <p><em>Type</em>: String
                              </p>
                              
                              <p><em>Update requires</em>: <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement">Replacement</a></p>
                              
                           </dd>
                           
                           
                           <dt><a id="cfn-route53-hostedzone-queryloggingconfig"></a><span class="term"><code class="code">QueryLoggingConfig</code></span></dt>
                           
                           <dd>
                              
                              <p>The configuration for DNS query logging.</p>
                              
                              <p><em>Required</em>: No
                              </p>
                              
                              <p><em>Type</em>: <a href="aws-properties-route53-hostedzone-queryloggingconfig.html">Route&#xA0;53 QueryLoggingConfig</a></p>
                              
                              <p><em>Update requires</em>: <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt">No interruption</a></p>
                              
                           </dd>
                           
                           
                           <dt><a id="cfn-route53-hostedzone-vpcs"></a><span class="term"><code class="code">VPCs</code></span></dt>
                           
                           <dd>
                              
                              <p>One or more VPCs that you want to associate with this hosted zone. When you
                                 specify this property, AWS CloudFormation creates a private hosted zone.
                              </p>
                              
                              <p><em>Required</em>: No
                              </p>
                              
                              <p><em>Type</em>: List of <a href="aws-resource-route53-hostedzone-hostedzonevpcs.html">Route&#xA0;53 HostedZoneVPCs</a></p>
                              
                              <p>If this property was specified previously and you&apos;re modifying values, updates
                                 require <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt">no interruption</a>. If this
                                 property wasn&apos;t specified and you add values, updates require <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement">replacement</a>. Also, if this property was
                                 specified and you remove all values, updates require <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement">replacement</a>.
                              </p>
                              
                           </dd>
                           
                        </dl>
                     </div><h2 id="w2ab1c21c10d201c18b9">Return Values</h2><h3 id="w2ab1c21c10d201c18b9b2">Ref</h3><p>When the logical ID of this resource is provided to the <code class="code">Ref</code> intrinsic function, <code class="code">Ref</code> returns the hosted zone ID, such as
                        <code class="code">Z23ABC4XYZL05B</code>.
                     </p><p>For more information about using the <code class="code">Ref</code> function, see <a href="intrinsic-function-reference-ref.html">Ref</a>.
                     </p><h3 id="w2ab1c21c10d201c18b9b4">Fn::GetAtt</h3><p><code class="code">Fn::GetAtt</code> returns a value for a specified attribute of this type.
                        The following are the available attributes and sample return values.
                     </p><div class="variablelist">
                        
                        
                        <dl>
                           
                           <dt><span class="term"><code class="literal">NameServers</code></span></dt>
                           
                           <dd>
                              
                              <p>Returns the set of name servers for the specific hosted zone. For example:
                                 <code class="code">ns1.example.com</code>.
                              </p>
                              
                              <p>This attribute is not supported for private hosted zones.</p>
                              
                           </dd>
                           
                        </dl>
                     </div><p>For more information about using 
                        <code class="code">Fn::GetAtt</code>, see 
                        <a href="intrinsic-function-reference-getatt.html">Fn::GetAtt</a>.
                        
                     </p><h2 id="w2ab1c21c10d201c18c11">Example</h2><p>The following template snippet creates a private hosted zone for the
                        <code class="code">example.com</code> domain.
                     </p><div id="JSON" name="JSON" class="section langfilter">
                        <h3 id="aws-resource-route53-hostedzone-example.json">JSON</h3>
                        
                        <pre class="programlisting"><div class="code-btn-container"><div class="btn-copy-code" title="Copy"></div><div class="btn-dark-theme" title="Dark theme" title-dark="Dark theme" title-light="Light theme"></div></div><code class="nohighlight ">&quot;DNS&quot;: {
  &quot;Type&quot;: &quot;AWS::Route53::HostedZone&quot;,
  &quot;Properties&quot;: {
    &quot;HostedZoneConfig&quot;: {
      &quot;Comment&quot;: &quot;My hosted zone for example.com&quot;
    },
    &quot;Name&quot;: &quot;example.com&quot;,
    &quot;VPCs&quot;: [{
      &quot;VPCId&quot;: &quot;vpc-abcd1234&quot;,
      &quot;VPCRegion&quot;: &quot;ap-northeast-1&quot;
    },
    {
      &quot;VPCId&quot;: &quot;vpc-efgh5678&quot;,
      &quot;VPCRegion&quot;: &quot;us-west-2&quot;
    }],
    &quot;HostedZoneTags&quot; : [{
      &quot;Key&quot;: &quot;SampleKey1&quot;,
      &quot;Value&quot;: &quot;SampleValue1&quot;
    },
    {
      &quot;Key&quot;: &quot;SampleKey2&quot;,
      &quot;Value&quot;: &quot;SampleValue2&quot;
    }]
  }
}</code></pre>
                        </div><div id="YAML" name="YAML" class="section langfilter">
                        <h3 id="aws-resource-route53-hostedzone-example.yaml">YAML</h3>
                        
                        <pre class="programlisting"><div class="code-btn-container"><div class="btn-copy-code" title="Copy"></div><div class="btn-dark-theme" title="Dark theme" title-dark="Dark theme" title-light="Light theme"></div></div><code class="nohighlight ">DNS: 
  Type: &quot;AWS::Route53::HostedZone&quot;
  Properties: 
    HostedZoneConfig: 
      Comment: &quot;My hosted zone for example.com&quot;
    Name: &quot;example.com&quot;
    VPCs: 
      - 
        VPCId: &quot;vpc-abcd1234&quot;
        VPCRegion: &quot;ap-northeast-1&quot;
      - 
        VPCId: &quot;vpc-efgh5678&quot;
        VPCRegion: &quot;us-west-2&quot;
    HostedZoneTags: 
      - 
        Key: &quot;SampleKey1&quot;
        Value: &quot;SampleValue1&quot;
      - 
        Key: &quot;SampleKey2&quot;
        Value: &quot;SampleValue2&quot;</code></pre>
                        </div></div>
</body>
</html>