Amazon Elastic Compute Cloud
User Guide (API Version 2013-02-01)
« PreviousNext »
View the PDF for this guide.Go to the AWS Discussion Forum for this product.Go to the Kindle Store to download this guide in Kindle format.Did this page help you?  Yes | No |  Tell us about it...

Terminating Instances

This topic describes how to terminate an Amazon EC2 instance.

If the instance you launched is not in the free usage tier, as soon as your instance starts to boot, you're billed for each hour or partial hour that you keep the instance running (even if the instance is idle). When you've decided that you no longer need an instance, you can terminate it. As soon as the status of an instance changes to shutting down or terminated, you stop incurring charges for that instance.

For information about the differences between stopping an instance and terminating an instance, see Stopping Instances. For information about preventing an instance from being terminated, see Enabling Termination Protection for an Instance.

You cannot restart a terminated instance. However, you can launch additional instances of the same AMI.

AWS Management Console

To terminate an instance

  1. Open the Amazon EC2 console at https://console.aws.amazon.com/ec2/.

  2. In the navigation pane, click Instances.

  3. Right-click the instance, and then click Terminate.

  4. Click Yes, Terminate when prompted for confirmation.

Command Line Tools

To terminate an instance, use the ec2-terminate-instances command. This example command terminates the instance with the ID i-10a64379.

ec2-terminate instances i-10a64379

The following is an example of the output for this command.

INSTANCE i-10a64379 running shutting-down

API

To terminate an instance, use the TerminateInstances command.