Security advisorywp2shell: WordPress core vulnerability. Updated August 4, 2026.

Read the advisory

WordPress salts

Definition

WordPress salts are secret keys in wp-config.php that help secure cookies, nonces, and related cryptographic operations.

Also called: security keys, AUTH_KEY, salt keys

Why it matters for WordPress

AUTH_KEY, SECURE_AUTH_KEY, and the other salts in wp-config.php make session cookies and nonces harder to forge. If those secrets leak (or you inherited a site with keys copied from a tutorial), attackers have an easier time with stolen cookies. Regenerating salts invalidates existing sessions. That is often what you want after a breach.

How it shows up in practice

  • Eight long random constants near the top of wp-config.php
  • Everyone logged out after you rotate salts (expected)
  • Compromised sites that still work for the attacker until salts and passwords both change
  • Starter configs that reused the same example keys across many sites

What to do

  1. Use unique, randomly generated keys from a trusted generator (WordPress.org provides one).
  2. After a compromise, regenerate salts and rotate passwords together.
  3. Never commit real salts to a public repository.
  4. Keep wp-config.php out of web-reachable backup dumps.

Go deeper

Want the full walkthrough?

This page stays short on purpose. The guide covers steps, examples, and what to check on a live WordPress site.

Open full guide

Nearby ideas in the dictionary

All terms →

Questions about WordPress salts

Are WordPress salts the same as my admin password?+

No. Your password is what you type at login. Salts are long secret keys in wp-config.php that help protect cookies and nonces. After a breach you usually change both: passwords for people, and salts so old sessions stop working.

Why does regenerating salts log everyone out?+

Session cookies depend on those keys. New salts make existing cookies invalid, which is the point after a compromise. Staff and customers simply sign in again.