You can delete security groups, if you no longer require them. Deleting a security group will delete all its rules.


Deleting a security group must meet the following conditions:

  • There are no ECS instances in the security group. About how to move the ECS instance out of the security group, see Add to or remove from a security group.
  • Ensure it is not referenced in the rules of another security group Add security group rules. You can delete a security group directly by following the steps described in this document, if the security group is authorized by another security group, you will see the error message shown in the following figure. Delete the corresponding authorization rule.


To delete a security group, follow these steps:

  1. Log on to the  ECS console.
  2. Select a region to display a list of all the security groups in the region.
  3. In the left-side navigation pane, click  Networks & Security >  Security Groups.
  4. Select one or more security groups. Click Delete.
  5. In the displayed Delete a security group dialog box, click OK.

Related API