Launch templates let you save ECS instance creation parameters—such as instance type, image, key pair, Resource Access Management (RAM) role, security group, and network settings—so you don't have to specify them every time you create an instance. After saving a template, you can launch instances in seconds with a single click or API call. You can also override any saved parameter at launch time, so templates stay flexible as your requirements change.
Launch templates do not store instance passwords.
Each template supports up to 30 versions. Because templates are immutable, you create a new version whenever you need to change parameters. When launching instances without specifying a version, ECS uses the template's default version—not necessarily the latest one.
Features and benefits
Launch templates provide the following features and benefits:
Preset parameters: Preset ECS instance creation parameters—such as instance type, operating system, hardware settings, network settings, security rules, and storage settings—in a launch template for reuse.
Standardization and consistency: Use a launch template to create instances with identical configurations and environments, reducing the risk of human error in configuration.
Quick deployment: Create ECS instances from a launch template without specifying instance parameters each time.
Version control and iteration: Create different versions of a launch template to iterate, optimize, or suit different projects.
Use cases
Consistent environments: Use one template to create development, testing, and production instances with identical configurations, reducing configuration drift.
Auto Scaling: Attach a template to a scaling group. Auto Scaling uses the template's parameters to provision instances automatically. Override specific parameters on the Create Scaling Group page if needed. For more information, see Create a scaling group based on an existing ECS instance.
Auto Provisioning: Auto provisioning groups use templates as configuration sources to provision and start an instance cluster at a specified time, improving large-scale provisioning efficiency. For more information, see Create an auto provisioning group.
CI/CD pipelines: Integrate templates with your continuous integration/continuous deployment (CI/CD) pipeline to deploy code to pre-configured environments rapidly.
Disaster recovery: Quickly replicate instance configurations when setting up disaster recovery plans.
Limits
| Constraint | Limit |
|---|---|
| Launch templates per account per region | 30 |
| Versions per launch template | 30 |
| Template mutability | Immutable — create a new version to change parameters |
| Required parameters | All parameters are optional in the template. If required parameters (such as instance type and image) are absent, specify them at instance creation time |
| Default version | Cannot be deleted directly — change the default version first, then delete the old version |
Billing
Launch templates are free. Charges apply to the ECS resources you create using a template. For details, see Billing overview.
Create a launch template
Store your instance configuration in a template so you can reuse it across projects, environments, or auto-scaling scenarios.
Use the ECS console
In the top navigation bar, select the target region and resource group.

On the Launch Templates page, click Create Template.
On the Launch Template page, specify parameters in the Basic Configurations (Optional) and Advanced Configurations (Optional) steps.
All parameters are optional. If you have already created a template, select it in the Clone Template section to use it as a starting point. The Clone Template section is unavailable the first time you create a template. In the Instance Type section, use the Scenario-based Selection tab to filter instance types by your use case.
In the Confirm Configurations step, configure the following settings, then click Create Launch Template.
Save As: Select how to save the current configuration.
Create Template: Saves the configuration as the default version of a new template.
Create Version: Saves the configuration as the latest version of an existing template.
Template Name and Version Description: Enter a name and description to facilitate future management.
Template Resource Group: Select a resource group to assign the template to. To create a new resource group, click here to open the Create Resource Group page. For more information, see Resource groups.
Click the
icon in the Basic Configurations or Advanced Configurations sections to modify parameters before saving.
In the Success message, click View Template to confirm the template in the ECS console.
Call an API operation
Call CreateLaunchTemplate to create a launch template.
Use a launch template to create an ECS instance
Select any version of a template to create one or more instances without re-entering parameters. If a template omits required parameters, specify them at this step — the template's saved values are pre-loaded and can be overridden.
Prerequisites
Before you begin, ensure that you have an existing launch template or template version to use.
Use the ECS console
On the Launch Templates page, find the template and click Create Instance in the Actions column. Alternatively, click a template ID to view its versions, then click Create Instance next to the version you want to use.

On the Custom Launch tab, the selected template and version are automatically loaded. Review all configurations.
To modify any parameter or add missing required values, click the
icon. You can override any template parameter at this step without changing the template itself.Create the instance based on your billing preference. After creation, go to the Instance page in the ECS console to view the new instance.
Subscription: Set the Duration, accept the ECS Terms of Service and Product Terms of Service, then click Create Order.
Pay-as-you-go: Accept the ECS Terms of Service and Product Terms of Service, then click Create Instance.
Call an API operation
Call RunInstances with the LaunchTemplateId and LaunchTemplateVersion parameters to batch create instances without specifying each parameter individually.
Delete a launch template
What's next
Provisioning methods of ECS instances: Learn about methods to batch create ECS instances.
References
DescribeLaunchTemplates: Query available launch templates.
DescribeLaunchTemplateVersions: Query the versions of a launch template.

