# AWS Fargate

> AWS Fargate is a serverless compute engine for containers that runs ECS and EKS workloads without managing servers or clusters of instances.

- Source: https://www.itwonderlab.com/aws-fargate/
- Published: 2023-11-22
- Updated: 2026-10-05
- Author: Javier Ruiz Jiménez (https://www.javierruizjimenez.com/)
- Site: IT Wonder Lab (https://www.itwonderlab.com/)

---

AWS Fargate is a serverless compute engine for containers. It allows users to run containers without managing the underlying infrastructure. With Fargate, you specify your container requirements (CPU, memory, networking), and AWS handles the provisioning and scaling of the infrastructure to run your containers. Users only pay for the resources consumed by their containers, making it a convenient and cost-effective way to deploy and manage containerized applications.

Fargate works with [Amazon ECS](https://www.itwonderlab.com/aws-ecs/) and [Amazon EKS](https://www.itwonderlab.com/aws-eks/). Each task or pod runs in its own isolated environment, with its own network interface in a [subnet](https://www.itwonderlab.com/aws-subnets/) of your [VPC](https://www.itwonderlab.com/aws-vpc/), and is billed per second for the vCPU, memory and storage that it requests. Images are pulled from [ECR](https://www.itwonderlab.com/aws-ecr/) or other registries. Unlike [EC2](https://www.itwonderlab.com/aws-ec2/) instances, there is no operating system to patch and no cluster capacity to plan.

In Terraform, Fargate is selected with `launch_type = "FARGATE"` (or a capacity provider) in an `aws_ecs_service`, or with an `aws_eks_fargate_profile` for EKS.

See tutorials:

-   [How to Deploy Containers in AWS ECS with Terraform and Fargate](https://www.itwonderlab.com/containers-aws-ecs-terraform-fargate/)
