Certificate error caused by a wrong device clock (NET::ERR_CERT_DATE_INVALID, "your clock is ahead/behind")
The site's certificate is valid, but the computer's date or time is wrong, so the browser thinks it is expired or not yet valid.
Your clock is aheadYour clock is behindNET::ERR_CERT_DATE_INVALID clockcertificate is not yet valid system date wrongthe date and time on your computer are incorrect Meaning
Set the date, time and timezone to automatic, sync NTP (w32tm /resync, timedatectl), and fix a dead CMOS battery or a VM with a paused clock. After a fix, restart the browser.
Common causes
- Device date/time wrong
- Dead CMOS battery or reset BIOS clock
- VM/snapshot resumed with an old clock
- Timezone/NTP disabled
- Certificate truly expired (check separately)
⚡ Quick fix
- Enable automatic date/time sync
- Run
w32tm /resyncorchronyc makestep - Compare with the real validity dates
Detailed fix by platform
Shell
- bash
timedatectl status openssl s_client -connect example.com:443 </dev/null 2>/dev/null | openssl x509 -noout -dates
How to diagnose
- Clock — Correct?
- NTP — Enabled?
- Cert dates — Valid?
🔧 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
- ACM region CloudFront can't use my ACM certificate: it must be requested in us-east-1 (N. Virginia)
- cert mismatch SMTP TLS certificate verification failed: hostname mismatch / unable to get local issuer (mail client or library)
- Cookie Cookie expires immediately or never because of clock skew or a wrong Expires date
Most viewed in SSL / TLS
- HTTPSConnectionPool: Max retries exceeded (SSLError) Python requests: HTTPSConnectionPool(host='api.example.com', port=443): Max retries exceeded with url: /v1 (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] ...')))
- DST Root CA X3 expired (old clients fail) Old clients: certificate has expired — Let's Encrypt chain uses expired DST Root CA X3 (OpenSSL 1.0.x, Android < 7.1.1)
- Keystore was tampered with, or password was incorrect Java keytool: java.io.IOException: Keystore was tampered with, or password was incorrect
Other ways to find it
Where this error sits
Origin: Network. 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 18 Nov 2026