Az group list

This Azure CLI article will discuss the syntax and usage of the az group list Azure CLI command with an example of how to use this command.

Az group list

This Azure CLI command can help you to retrieve the lists of Azure Resource Groups.

Syntax of az group list

Below is the syntax of the az group list command.

az group list

Let’s discuss an example of how to use the az group list command.

Example

Execute the below command to get the lists of resource groups.

az group list

After executing the above command, I got the output as expected.

PS /home/bijay> az group list                                                                                                                                               [      
  {
    "id": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/resourceGroups/cloud-shell-storage-centralindia",
    "location": "centralindia",
    "managedBy": null,
    "name": "cloud-shell-storage-centralindia",
    "properties": {
      "provisioningState": "Succeeded"
    },
    "tags": null,
    "type": "Microsoft.Resources/resourceGroups"
  },
  {
    "id": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/resourceGroups/MyNewResGrp",
    "location": "centralus",
    "managedBy": null,
    "name": "MyNewResGrp",
    "properties": {
      "provisioningState": "Succeeded"
    },
    "tags": null,
    "type": "Microsoft.Resources/resourceGroups"
  },
  {
    "id": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/resourceGroups/TsinfoNew_group",
    "location": "centralus",
    "managedBy": null,
    "name": "TsinfoNew_group",
    "properties": {
      "provisioningState": "Succeeded"
    },
    "tags": null,
    "type": "Microsoft.Resources/resourceGroups"
  },
  {
    "id": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/resourceGroups/demo357",
    "location": "centralus",
    "managedBy": null,
    "name": "demo357",
    "properties": {
      "provisioningState": "Succeeded"
    },
    "tags": null,
    "type": "Microsoft.Resources/resourceGroups"
  },
  {
    "id": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/resourceGroups/demo358",
    "location": "centralus",
    "managedBy": null,
    "name": "demo358",
    "properties": {
      "provisioningState": "Succeeded"
    },
    "tags": null,
    "type": "Microsoft.Resources/resourceGroups"
  },
  {
    "id": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/resourceGroups/Demo12346",
    "location": "centralus",
    "managedBy": null,
    "name": "Demo12346",
    "properties": {
      "provisioningState": "Succeeded"
    },
    "tags": null,
    "type": "Microsoft.Resources/resourceGroups"
  }

You can check out the screenshot below, where I have executed the az group list command and retrieved the lists of available Resource Groups as expected.

az group list

You may also like following the related articles below

Conclusion

This article discussed the syntax and usage of the az group list Azure CLI command with examples of how to use this command. Thanks for reading this article !!!