List Saved Windows Credentials with cmdkey

cmdkey /list shows everything stored in Windows Credential Manager — the forgotten CLI for stale logins and RDP entries.

WindowscredentialsadmincliLow risk
Run cmdkey /list to enumerate stored credentials, and cmdkey /delete:<target> to remove one.

01Command

Command
$ cmdkey /list

02What it does

When a password changes on a server and Windows keeps silently sending the old one, the culprit is a cached entry in Credential Manager that most users only know how to reach through the Control Panel. cmdkey lists, adds and deletes these entries entirely from the command line, which makes it easy to script cleanup across machines. Note it shows target names but never the secrets themselves.

03Risk

RiskLow risk
!Warning: Deleting a credential can break automated access to that resource until you re-enter the password.

04Undo

Undo
$ cmdkey /delete:TERMSRV/server01

05Sources

  • cmdkey (Windows Commands)
    Microsoft Learn · vendor-doc · 2026-09-17
    Evidence: Documents cmdkey /list to display stored credentials, /add to create them, and /delete to remove them.
  • Credentials Protection and Management
    Microsoft Learn · vendor-doc · 2026-09-17
    Evidence: Explains the Windows credential storage that cmdkey manages and related protections.

Last verified: 2026-09-17 · Category: Security & Privacy