Difference between regrate vs refresh vs rotate storage account key in Azure Portal?

Karolina-7697 5 Reputation points
2025-03-07T22:09:30.55+00:00

I need to change the key that is currently used on the Storage Account app in my company without anyone loosing the access in the process.

Here is what I found on Microsoft website:

To rotate your storage account access keys in the Azure portal:

  1. Update the connection strings in your application code to reference the secondary access key for the storage account.
  2. Navigate to your storage account in the Azure portal.
  3. Under Security + networking, select Access keys.
  4. To regenerate the primary access key for your storage account, select the Regenerate button next to the primary access key.
  5. Update the connection strings in your code to reference the new primary access key.
  6. Regenerate the secondary access key in the same manner.

How do I complete step 1?

Step 4 - there is no Regenerate button. Next to each key there is only a Rotate button, and above the refresh one.

Please help me with this issue.

Azure Storage Explorer
Azure Storage Explorer
An Azure tool that is used to manage cloud storage resources on Windows, macOS, and Linux.
292 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Amrinder Singh 5,870 Reputation points Microsoft Employee Volunteer Moderator
    2025-03-08T03:15:27.6633333+00:00

    Hi Karolina-7697

    Thanks for reaching out on Q&A Forum.

    This is the button you will tend to see for rotation/re-generation of the keys and will provide you the new one.

    User's image

    This in turn will expire the older Keys/connection string that was created via the older access keys and also any SAS signature too that was signed using the older access keys.

    There is no data loss as part of rotation/re-generation however the application will face connectivity/auth related failure as the older keys becomes invalid. You need to ensure you are updating the access keys / connection string / new SAS generated via new access keys for seamless connectivity.

    You can refer to this link as well

    https://learn.microsoft.com/en-us/azure/storage/common/storage-account-keys-manage?tabs=azure-portal

    Please let us know if you have any further queries. I’m happy to assist you further.

    Please do not forget to "Accept the answer” and “up-vote” wherever the information provided helps you, this can be beneficial to other community members. 


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.