// troubleshooting guide · aws cloudfront
CloudFront 504 Gateway Timeout Error
- Status
- Workaround available
- platforms:
- AWS Console, EC2, ALB, API origins
- updated:
- November 17, 2026
- reports:
- 5
- Method
- how we research
RUNBOOK · aws-cloudfront/504-gateway-timeout4 FIXES
// quick answer
A 504 means the origin didn't connect or respond in time: by default CloudFront tries 3 connections of 10 seconds each and waits 30 seconds for a response. Open the origin firewall to CloudFront, speed up the endpoint, then raise the origin response timeout if needed.
Most likely fix: Allow CloudFront to reach the origin
How to fix it
// try these in order, the most common fix is first
FIX 1Allow CloudFront to reach the origin
- 01Add the AWS managed prefix list com.amazonaws.global.cloudfront.origin-facing to the origin security group on ports 80/443
- 02Check NACLs and on-host firewalls
- 03Test from outside with curl -v https://origin.example.com
Did this fix it?FIX 2Raise the origin response timeout
- 01Open the distribution > Origins > select origin > Edit
- 02Under Additional settings increase Response timeout (default 30 seconds)
- 03Request a quota increase in Service Quotas if you need more than the console allows
- 04Save and wait for deployment
Did this fix it?FIX 3Make the slow endpoint asynchronous
- 01Return 202 Accepted immediately and process the job in the background
- 02Let the client poll a status endpoint or receive a webhook
- 03Keep CloudFront timeouts short so failures surface fast
Did this fix it?FIX 4Check AWS Health for incidents
- 01Open health.aws.amazon.com or the AWS Health Dashboard in the console
- 02Look for CloudFront or regional events before changing configuration
Did this fix it?
Symptoms
504 ERROR 'The request could not be satisfied' after roughly 30 seconds, typically on slow API calls, uploads or report generation.
Why it happens
- C-01Origin security group or firewall blocks CloudFront IP ranges
- C-02Endpoint takes longer than the 30-second default response timeout
- C-03Origin overloaded or keep-alive settings shorter than CloudFront's
- C-04VPC origin connectivity problems (as in the July 2026 incident)
// this guide also covers
- cloudfront 504 gateway timeout
- cloudfront timeout 30 seconds
- increase cloudfront origin response timeout
- cloudfront 504 error
Still not working?
If AWS CloudFront keeps failing, you're not alone. See every AWS CloudFront problem users report or the alternatives people switch to.
Have an app idea? Our small team builds any software: web and mobile apps, games, desktop, AI tools. Price agreed together.
Talk to usThe same problem in other apps
All not loading, error messages & connection guides →
Cloudflare Error 521: Web Server Is Down (Cloudflare)
Fastly Error: Unknown Domain (Fastly)
Google Cloud Quota Exceeded Error (Google Cloud)
Netlify Page Not Found on Refresh (SPA 404) (Netlify)
Other AWS CloudFront errors
- CloudFront 403 Access Denied With S3 Origin
- CloudFront 403 Error: The Request Could Not Be Satisfied
- CloudFront Invalidation Not Working (Still Serving Old Content)
- CloudFront CORS Error: No 'Access-Control-Allow-Origin' Header
- CloudFront SSL Certificate Not Showing (ACM us-east-1)
- CloudFront 502 Bad Gateway Error
- CloudFront React App 403/404 on Page Refresh
- Why Is My CloudFront Bill So High?