---
title: "The license key keeps disappearing"
date: 2026-04-23
author: "GravityKit"
link: "https://www.gravitykit.com/docs/general-help/licensing/the-license-key-keeps-disappearing/"
---

If your GravityKit license keys suddenly show as inactive, or you see a **"Licensing data is inaccessible"** notice on the *GravityKit → Manage Your Kit* page, it almost always comes down to a change in WordPress's secret keys (the salts defined in `wp-config.php`). GravityKit encrypts your licensing data with those keys, so when they change, the stored data can no longer be decrypted and your products appear unlicensed.

---

## What changes your secret keys

Something in your environment regenerated the WordPress secret keys. The usual causes:

- **Site migrations, server moves, or copying between staging and production.** A new environment brings a fresh `wp-config.php` with new salts, so license data carried over from the old database no longer matches. This is the most common cause.
- **Security plugins that rotate keys automatically**, such as [Sucuri Security](https://wordpress.org/plugins/sucuri-scanner/), [WP Defender](https://wordpress.org/plugins/defender-security/), and [Salt Shaker](https://wordpress.org/plugins/salt-shaker/).
- **Your hosting provider** rotating the keys, sometimes automatically on a schedule.
- **Migration or backup plugins** that regenerate salts when importing a site.

---

## Restore your license right now

Re-enter your license key on the *GravityKit → Manage Your Kit* page. Re-adding the license fetches a fresh copy from our server and re-encrypts it with your current keys, which clears the notice right away.

If the site is connected to your GravityKit account, the Licenses screen shows a **Reconnect** button instead. Reconnecting restores the licenses managed through the connection in one step; see [Managing Connected Sites](https://www.gravitykit.com/docs/general-help/licensing/managing-connected-sites/).

If you are told you have reached the activation limit, earlier attempts may have used up your activation slots. [Contact our support team](https://www.gravitykit.com/support) and we will reset them for you.

---

## Prevent it from happening again

Re-adding the key fixes the immediate problem, but if something keeps changing your secret keys the notice will return. To make your licensing immune to key changes:

- **Define a `GRAVITYKIT_SECRET_KEY` constant (recommended).** Add a line such as `define( 'GRAVITYKIT_SECRET_KEY', '' );` to `wp-config.php`, using a long random value (you can [generate one here](https://api.wordpress.org/secret-key/1.1/salt/)). GravityKit then encrypts your licensing data with this stable key instead of the rotating WordPress salts, so it survives any future key change no matter what caused it.
- [Hard-code your license keys](https://www.gravitykit.com/docs/general-help/licensing/hard-coding-your-license-key/) so they are set in your configuration rather than stored encrypted in the database.
- **Stop the source from rotating keys.** Turn off automatic key regeneration in your security plugin (steps below), or ask your hosting provider not to rotate the keys.

If you are confident that your security keys have not changed and you are still seeing this issue, please [contact our support team](https://www.gravitykit.com/support) for further assistance.

---

## Disabling security key rotation in Sucuri Security

- Go to *Sucuri Security → Settings* in your WordPress admin dashboard.
- Select the *Hardening* tab.
- Disable the *Activate Automatic Secret Keys Updater* option.

![WP Plugin Hardening options list with actions like "Apply Hardening" and "Revert Hardening" buttons](https://www.gravitykit.com/wp-content/uploads/2025/10/file-vY1UlP0teS.png)

## Disabling security key rotation in WP Defender

- Go to *Defender → Recommendations* in your WordPress admin dashboard.
- Open *Update old security keys* (look in the *Actioned* list if you have run it before).
- Untick *Automatically regenerate security keys*.

![WP Defender Recommendations: the Update old security keys panel with Automatically regenerate security keys enabled and a 60-day reminder frequency](https://www.gravitykit.com/wp-content/uploads/2026/04/ticket-72485-defender.png)