

# Create an Auto Scaling group using the Amazon EC2 launch wizard
<a name="create-asg-ec2-wizard"></a>

The following procedure shows how to create an Auto Scaling group by using the **Launch instance** wizard in the Amazon EC2 console. This option automatically populates a launch template with certain configuration details from the **Launch instance** wizard.

**Note**  
The wizard does not populate the Auto Scaling group with the number of instances you specify; it only populates the launch template with the Amazon Machine Image (AMI) ID and instance type. Use the **Create Auto Scaling group** wizard to specify the number of instances to launch.   
An AMI provides the information required to configure an instance. You can launch multiple instances from a single AMI when you need multiple instances with the same configuration. We recommend using a custom AMI that already has your application installed on it to avoid having your instances terminated if you reboot an instance belonging to an Auto Scaling group. To use a custom AMI with Amazon EC2 Auto Scaling, you must first create your AMI from a customized instance, and then use the AMI to create a launch template for your Auto Scaling group.

**Prerequisites**
+ You must have created a custom AMI in the same AWS Region where you plan to create the Auto Scaling group. For more information, see [Create an AMI](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/creating-an-ami-ebs.html) in the *Amazon EC2 User Guide*.

## Use a custom AMI as a template
<a name="create-asg-ec2-wizard-launch-template"></a>

In this section, you use the Amazon EC2 launch wizard to automatically populate a launch template with your custom AMI. Alternatively, to set up the launch template from scratch or for more description of the parameters you can configure for your launch template, see [Create your launch template (console)](create-launch-template.md#create-launch-template-for-auto-scaling).

**To use a custom AMI as a template**

1. Open the Amazon EC2 console at [https://console.aws.amazon.com/ec2/](https://console.aws.amazon.com/ec2/).

1. On the navigation bar at the top of the screen, the current AWS Region is displayed. Select a Region in which to launch your Auto Scaling group.

1. In the navigation pane, choose **Instances**.

1. Choose **Launch instance**, and then do the following:

   1. Under **Name and tags**, leave **Name** blank. The name isn't part of the data that's used to create a launch template. 

   1. Under **Application and OS Images (Amazon Machine Image)**, choose **Browse more AMIs** to browse the full AMI catalog.

   1. Choose **My AMIs**, find the AMI that you created, and then choose **Select**. 

   1. Under **Instance type**, choose an instance type. 
**Note**  
Choose the same instance type that you used when you created the AMI or a more powerful one.

   1. On the right side of the screen, under **Summary**, for **Number of instances**, enter any number. The number that you enter here isn't important. You will specify the number of instances that you want to launch when you create the Auto Scaling group.

      Under the **Number of instances** field, a message displays that says **When launching more than 1 instance, consider EC2 Auto Scaling**. 

   1. Choose the **consider EC2 Auto Scaling** hyperlink text.

   1. On the **Launch into Auto Scaling Group** confirmation dialogue, choose **Continue** to go to the **Create launch template** page with the AMI and instance type you selected in the launch instance wizard already populated.

After you choose **Continue**, the **Create launch template** page opens. Follow this procedure to finish creating a launch template. 

**To create a launch template**

1. Under **Launch template name and description**, enter a name and description for the new launch template.

1. (Optional) Under **Key pair (login)**, for **Key pair name**, choose the name of the previously created key pair to use when connecting to instances, for example, using SSH.

1. (Optional) Under **Network settings**, for **Security groups**, choose one or more previously created [security groups](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-security-groups.html).

1. (Optional) Under **Configure storage**, update the storage configuration. The default storage configuration is determined by the AMI and the instance type. 

1. When you are done configuring the launch template, choose **Create launch template**.

1. On the confirmation page, choose **Create Auto Scaling group**.

## Create an Auto Scaling group
<a name="create-asg-ec2-wizard-auto-scaling-group"></a>

**Note**  
The rest of this topic describes the basic procedure for creating an Auto Scaling group. For more description of the parameters you can configure for your Auto Scaling group, see [Create an Auto Scaling group using a launch template](create-asg-launch-template.md).

After you choose **Create Auto Scaling group**, the **Create Auto Scaling group** wizard opens. Follow this procedure to create an Auto Scaling group.

**To create an Auto Scaling group**

1. On the **Choose launch template or configuration** page, enter a name for the Auto Scaling group.

1. The launch template that you created is already selected for you. 

   For **Launch template version**, choose whether the Auto Scaling group uses the default, the latest, or a specific version of the launch template when scaling out.

1. Choose **Next** to continue to the next step.

1. On the **Choose instance launch options** page, if you're not using multiple instance types, you can skip the **Instance type requirements** section to use the EC2 instance type that is specified in the launch template.

   To use multiple instance types, see [Auto Scaling groups with multiple instance types and purchase options](ec2-auto-scaling-mixed-instances-groups.md).

1. Under **Network**, for **VPC**, choose a VPC. The Auto Scaling group must be created in the same VPC as the security group you specified in your launch template.
**Tip**  
If you didn't specify a security group in your launch template, your instances are launched with a default security group from the VPC that you specify. By default, this security group doesn't allow inbound traffic from external networks.

1. For **Availability Zones and subnets**, choose one or more subnets in the specified VPC.

1. For **Availability Zone distribution**, select a distribution strategy. For more information, see [Auto Scaling group Availability Zone distribution](ec2-auto-scaling-availability-zone-balanced.md).

1. Choose **Next** twice to go to the **Configure group size and scaling policies** page.

1. Under **Group size**, define the **Desired capacity** (initial number of instances to launch immediately after the Auto Scaling group is created).

1. In the **Scaling** section, under **Scaling limits**, if your new value for **Desired capacity** is greater than **Min desired capacity** and **Max desired capacity**, the **Max desired capacity** is automatically increased to the new desired capacity value. You can change these limits as needed. For more information, see [Set scaling limits for your Auto Scaling group](asg-capacity-limits.md).

1. Choose **Skip to review**. 

1. On the **Review** page, choose **Create Auto Scaling group**.

## Next steps
<a name="create-asg-ec2-wizard-next-steps"></a>

You can check that the Auto Scaling group has been created correctly by viewing the activity history. On the **Activity** tab, under **Activity history**, the **Status** column shows whether your Auto Scaling group has successfully launched instances. If the instances fail to launch or they launch but then immediately terminate, see the following topics for possible causes and resolutions:
+ [Troubleshoot Amazon EC2 Auto Scaling: EC2 instance launch failures](ts-as-instancelaunchfailure.md)
+ [Troubleshoot Amazon EC2 Auto Scaling: AMI issues](ts-as-ami.md)
+ [Troubleshoot unhealthy instances in Amazon EC2 Auto Scaling](ts-as-healthchecks.md)

You can now attach a load balancer in the same Region as your Auto Scaling group, if desired. For more information, see [Use Elastic Load Balancing to distribute incoming application traffic in your Auto Scaling group](autoscaling-load-balancer.md).