How to Manage Secrets in the Control Panel
Last verified 3 Nov 2026
DigitalOcean Secrets Manager provides a central place to store and manage sensitive values used by applications running on DigitalOcean.
Create, update, revert, delete, and restore DigitalOcean Secrets Manager secrets on the Secrets page of the DigitalOcean Control Panel. A secret can contain one or more key-value pairs, such as a username, password, API key, or access token.
Before You Begin
Make sure you have:
- Access to the DigitalOcean team where the secret will be created.
- Permission to create and update secrets. See Access and Permissions.
- A name for the secret.
- The DigitalOcean region where the secret will be stored.
- The keys and values required by your application.
Create a Secret
To create a secret:
- Go to the Secrets page.
- Click Create Secret.
- Enter a unique name for the secret.
- Select the region where the secret will be stored.
- Enter a key and its value.
- Add any additional key-value pairs required by your application.
- Click Create Secret.
After the secret is created, its details page displays the active version and the keys contained in the secret. Secret values are masked after they are stored.
Update a Secret
Updating a secret creates a new active version and keeps the same secret name.
To update a secret:
- Go to the Secrets page.
- Select the secret you want to update.
- Add, change, or remove the required key-value pairs.
- Review the updated values.
- Click Save Changes.
After the update is complete, verify that the new version is active. Applications continue to use the same secret name.
Revert to a Previous Version
Reverting a secret copies the values from a retained version into a new active version. The secret’s name stays the same, so applications continue to reference the same secret. To revert a secret:
- Go to the Secrets page.
- Select the secret you want to revert.
- Click the Version history tab.
- Find the version whose values you want to use, then click Revert beside that version.
- In the Revert to this version? confirmation dialog, verify the version number and click Create new version.
The new version appears at the top of Version history with the Current label. For example, reverting to Version 1 when Version 2 is current creates Version 3 containing Version 1’s values.
Secrets Manager retains the five most recent versions. If reverting creates a sixth version, the oldest retained version is removed.
Verify that your applications can retrieve and use the reverted values. Reverting a secret does not change the credential in the system that validates it. A previously revoked password, token, or key remains invalid.
Delete a Secret
Deleting a secret schedules it for deletion and makes its values unavailable. Secrets Manager permanently deletes the secret after 7 days unless you restore it. Before deleting a secret, make sure your applications no longer depend on retrieving it. To delete a secret:
- Go to the Secrets page.
- Select the secret you want to delete.
- Click Delete secret.
- In the confirmation dialog, copy the displayed secret name and paste it into the Name field. The name must match exactly before the Delete secret button becomes available.
- Click Delete secret to confirm.
The Control Panel displays a deletion confirmation and returns you to the secrets list, which hides deleted secrets by default. To display them with a Deleted label, turn on Show deleted.
Restore a Deleted Secret
You can restore a secret that is scheduled for deletion to make its values available again. To restore a secret:
- Go to the Secrets page.
- Turn on Show deleted.
- Select the secret marked Deleted that you want to restore.
- On the secret’s details page, click Restore secret.
- In the Restore this secret? confirmation dialog, click Restore secret.
- Open the Values tab and click Fetch and reveal secret to retrieve the restored secret’s contents.
- Confirm that the expected keys are present.
- Verify that your applications can retrieve and use the secret again.
Protect Secret Values
- Do not store secret values in source control.
- Do not include secret values in screenshots, logs, or support requests.
- Avoid copying secret values into shared documents or messaging tools.
- Grant secret access only to the users and workloads that require it.