Amazon Route 53
API Reference


Disassociates a VPC from a Amazon Route 53 private hosted zone. Note the following:

  • You can't disassociate the last VPC from a private hosted zone.

  • You can't convert a private hosted zone into a public hosted zone.

  • You can submit a DisassociateVPCFromHostedZone request using either the account that created the hosted zone or the account that created the VPC.

Request Syntax

POST /2013-04-01/hostedzone/Id/disassociatevpc HTTP/1.1 <?xml version="1.0" encoding="UTF-8"?> <DisassociateVPCFromHostedZoneRequest xmlns=""> <Comment>string</Comment> <VPC> <VPCId>string</VPCId> <VPCRegion>string</VPCRegion> </VPC> </DisassociateVPCFromHostedZoneRequest>

URI Request Parameters

The request requires the following URI parameters.


The ID of the private hosted zone that you want to disassociate a VPC from.

Length Constraints: Maximum length of 32.

Request Body

The request accepts the following data in XML format.


Root level tag for the DisassociateVPCFromHostedZoneRequest parameters.

Required: Yes


Optional: A comment about the disassociation request.

Type: String

Required: No


A complex type that contains information about the VPC that you're disassociating from the specified hosted zone.

Type: VPC object

Required: Yes

Response Syntax

HTTP/1.1 200 <?xml version="1.0" encoding="UTF-8"?> <DisassociateVPCFromHostedZoneResponse> <ChangeInfo> <Comment>string</Comment> <Id>string</Id> <Status>string</Status> <SubmittedAt>timestamp</SubmittedAt> </ChangeInfo> </DisassociateVPCFromHostedZoneResponse>

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in XML format by the service.


Root level tag for the DisassociateVPCFromHostedZoneResponse parameters.

Required: Yes


A complex type that describes the changes made to the specified private hosted zone.

Type: ChangeInfo object


For information about the errors that are common to all actions, see Common Errors.


The input is not valid.

HTTP Status Code: 400


The VPC ID that you specified either isn't a valid ID or the current account is not authorized to access this VPC.

HTTP Status Code: 400


The VPC that you're trying to disassociate from the private hosted zone is the last VPC that is associated with the hosted zone. Amazon Route 53 doesn't support disassociating the last VPC from a hosted zone.

HTTP Status Code: 400


No hosted zone exists with the ID that you specified.

HTTP Status Code: 404


The specified VPC and hosted zone are not currently associated.

HTTP Status Code: 404


Example Request

POST /2013-04-01/hostedzone/Z1PA6795UKMFR9/disassociatevpc HTTP/1.1 <?xml version="1.0"?> <VPC> <VPCId>vpc-a1b2c3d4e5</VPCId> <VPCRegion>us-east-2</VPCRegion> </VPC> </DisassociateVPCFromHostedZoneRequest>

Example Response

HTTP/1.1 200 OK <?xml version="1.0" encoding="UTF-8"?> <DisassociateVPCFromHostedZoneResponse xmlns=""> <ChangeInfo> <Id>/change/a1b2c3d4</Id> <Status>INSYNC</Status> <SubmittedAt>2017-03-31T01:36:41.958Z</SubmittedAt> </ChangeInfo> </DisassociateVPCFromHostedZoneResponse>

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: