Recently, I got the requirement to use the az keyvault list-deleted command. In this article, I will take you through the syntax and the usage of the az keyvault list-deleted command with examples.
Table of Contents
Az keyvault list-deleted
This command gets information about the deleted Vaults or HSMs under a subscription.
Syntax
az keyvault list-deleted [--resource-type]Example
The below command will get you the lists of Azure key vaults deleted under a subscription.
az keyvault list-deletedAfter executing the above command, I got the expected output as shown below.
[
{
"id": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/providers/Microsoft.KeyVault/locations/eastus/deletedVaults/azurelessonsKV",
"name": "azurelessonsKV",
"properties": {
"deletionDate": "2025-01-30T13:52:11+00:00",
"location": "eastus",
"purgeProtectionEnabled": null,
"scheduledPurgeDate": "2025-04-30T13:52:11+00:00",
"tags": {},
"vaultId": "/subscriptions/1cdf4300-dee5-4518-9c9c-feaa72a5cbd1/resourceGroups/MyNewResGrp/providers/Microsoft.KeyVault/vaults/azurelessonsKV"
},
"type": "Microsoft.KeyVault/deletedVaults"
}
]You can see the same output in the screenshot below.

If you accidentally delete the Azure key vault, you can use the az keyvault recover to recover the deleted Azure key vault.
You may also like following the articles below.
- Az keyvault list
- How To Create Secret In Azure Key Vault
- The Access Configuration For This Key Vault Is Set To Role-Based Access Control.

I am Rajkishore, and I am a Microsoft Certified IT Consultant. I have over 14 years of experience in Microsoft Azure and AWS, with good experience in Azure Functions, Storage, Virtual Machines, Logic Apps, PowerShell Commands, CLI Commands, Machine Learning, AI, Azure Cognitive Services, DevOps, etc. Not only that, I do have good real-time experience in designing and developing cloud-native data integrations on Azure or AWS, etc. I hope you will learn from these practical Azure tutorials. Read more.
