- Newest
- Most votes
- Most comments
When your custom domain in API Gateway is not using your ACM certificate and is instead serving the default AWS certificate, this is typically due to one of several issues:
-
Propagation delay: When you create or update a custom domain with an ACM certificate in API Gateway, it can take up to 1 hour for the changes to fully propagate across AWS infrastructure. If you've recently set up the custom domain or changed the certificate, you may need to wait for this propagation to complete.
-
DNS configuration: Ensure that your DNS CNAME record is correctly pointing to the API Gateway domain name provided when you created the custom domain (not the execute-api endpoint). This is a common mistake that can cause certificate issues.
-
Certificate region: Verify that your ACM certificate is in the correct AWS region. For regional API Gateway endpoints, the certificate must be in the same region as your API Gateway.
-
Certificate validation: Although you mentioned the custom domain shows as "Available" in the console, double-check that the ACM certificate itself is fully validated and active.
-
API mapping configuration: The issue is not related to mapping a proxy API versus individual APIs - the certificate association happens at the custom domain level, not the API mapping level.
To resolve this issue:
- Wait at least an hour after making any changes to the custom domain or certificate
- Verify your DNS configuration is pointing to the correct domain name provided by API Gateway
- If needed, you can update the certificate association using the AWS CLI with the
update-domain-namecommand to reassign the certificate to your custom domain
If after these steps you still experience issues, you may need to delete and recreate the custom domain with the correct certificate, ensuring proper DNS configuration.
Sources
ACM Cert Not Being Honored By Custom Domain in Cognito | AWS re:Post
Custom Domain & API Gateway Connection suddenly disconnected. | AWS re:Post
API Gateway examples using AWS CLI - AWS SDK Code Examples
Relevant content
asked 3 years ago
- AWS OFFICIALUpdated 10 months ago
