- Newest
- Most votes
- Most comments
AWS Amplify is designed to handle scaling and growing traffic efficiently, leveraging AWS serverless technologies to automatically scale your application as needed.
When you deploy a NextJS application with AWS Amplify, it indeed uses services like AWS CloudFront and AWS Lambda behind the scenes. However, your understanding about Lambda limitations not applying to Amplify-hosted functions is not entirely correct.
Lambda functions, including those deployed through Amplify, are subject to the same concurrency and scaling limits as other Lambda functions in your AWS account. These limits do apply at the account level within a region, and they affect all Lambda functions, regardless of how they were deployed.
That being said, Lambda has impressive scaling capabilities. Each function can scale up to a rate of 1,000 concurrent executions every 10 seconds, up to your account's concurrency limit. This allows for rapid scaling in response to sudden traffic spikes.
If your application receives millions of requests per second hitting CloudFront and the Lambda functions hosted by Amplify, here's what would happen:
-
CloudFront would handle the initial load, distributing requests across its global network of edge locations.
-
The Lambda functions would start scaling up rapidly to handle the increased load, creating new execution environments as fast as the concurrency scaling rate allows.
-
If the traffic exceeds the Lambda scaling rate or reaches your account's concurrency limit, some requests may be throttled, resulting in errors.
To handle extremely high traffic scenarios, you might need to:
- Request a increase in your account's Lambda concurrency limit from AWS support.
- Implement caching strategies at the CloudFront level to reduce the load on your Lambda functions.
- Consider using provisioned concurrency for your Lambda functions to maintain a set number of pre-initialized execution environments.
Remember, while Amplify provides a seamless development and deployment experience, it's still subject to the underlying AWS service limits. For applications expecting extremely high traffic, it's crucial to design with these limits in mind and implement appropriate scaling and optimization strategies.
Sources
Lambda scaling behavior - AWS Lambda
AWS Lambda functions now scale up to 12X faster in the AWS GovCloud (US) Regions
AWS Amplify | Extensible Web & Mobile Apps | Amazon Web Services
answered 2 years ago
Relevant content
asked 5 years ago
- AWS OFFICIALUpdated 4 years ago
- AWS OFFICIALUpdated 10 months ago
- AWS OFFICIALUpdated 5 years ago

To handle extremely high traffic scenarios, you might need to:
Request a increase in your account's Lambda concurrency limit from AWS support ?
Is that necessary for this because I don't handle Cloudfront and Lambda that hosted by Amplify.