ERROR 1862 (HY000): Your password has expired. To log in you must change it using a client that supports expired passwords
The MySQL account's password has expired and the connection is restricted until it is changed.
Your password has expiredTo log in you must change it using a client that supports expired passwords Meaning
Password expiry policies (default_password_lifetime, PASSWORD EXPIRE) put the account in "sandbox mode": only ALTER USER ... IDENTIFIED BY and SET PASSWORD are allowed. Applications fail with this error until the password is reset.
Common causes
- Account created with
PASSWORD EXPIRE default_password_lifetimereached- Client library not supporting expired-password mode
- Service account with rotating policy
⚡ Quick fix
- Log in with the mysql client and run
ALTER USER USER() IDENTIFIED BY 'new' - Disable expiry for service accounts:
ALTER USER 'app'@'%' PASSWORD EXPIRE NEVER - Adjust
default_password_lifetime
Detailed fix by platform
MySQL
ALTER USER 'app'@'%' PASSWORD EXPIRE NEVER;
How to diagnose
- Policy — default_password_lifetime?
- Account — Per-user expiry?
- Client — Supports sandbox mode?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
Most viewed in MySQL
Other ways to find it
Where this error sits
Origin: Data. Errors that are often confused with or caused by this one (click to open):
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
💬 What worked for others
No tips yet — did something else fix this for you?
Share what worked for you
Tips are checked by an editor before they appear. Links are removed.
Report a correction or suggest an improvement
Last updated 2 Dec 2026