How to Remove Network Credentials in Windows 11

Windows 11 saves the usernames and passwords you use for network shares, NAS drives, other PCs and some apps, so you don’t have to type them each time. If a password changed, you connected with the wrong account, or you’re handing the PC to someone else, you’ll want to remove those saved network credentials. This guide covers Credential Manager, the cmdkey command, disconnecting cached network sessions, and forgetting saved Wi-Fi networks.

Quick Answer

Search for Credential Manager in Start, open Windows Credentials, click the saved entry for the server or PC, and click Remove. Restart or sign out so Windows stops using the cached connection.

Credential Manager on the Windows Credentials tab with a saved network server entry expanded and the Remove link highlighted
Expand a saved network credential and click Remove.

Method 1: Credential Manager

  1. Click Start, type Credential Manager, and open it. (It’s also in Control Panel > User Accounts > Credential Manager.)
  2. Click Windows Credentials.
  3. Under Windows Credentials, find the entry named after the server, NAS or PC, such as NAS-OFFICE or 192.168.1.20.
  4. Click the arrow to expand it, then click Remove and confirm with Yes.

Use Edit instead if you just need to update the password. The Web Credentials tab holds passwords saved by Microsoft Edge and some apps.

Method 2: cmdkey in Command Prompt

  1. Open Terminal or Command Prompt.
  2. List saved credentials:
    cmdkey /list
  3. Delete one by its target name:
    cmdkey /delete:NAS-OFFICE

    For domain-style targets, use the exact name shown, for example cmdkey /delete:Domain:target=NAS-OFFICE.

Method 3: Disconnect Cached Network Sessions

Windows keeps an open connection to a share even after you remove the credential, which is why the old account can still work until you restart. To drop connections immediately:

net use

lists them, and

net use * /delete

disconnects all mapped drives and sessions (type Y to confirm). To remove one, use net use \\NAS-OFFICE\share /delete. Then reconnect and enter the correct username and password.

Forget a Saved Wi-Fi Network

  1. Go to Settings > Network & internet > Wi-Fi > Manage known networks.
  2. Click Forget next to the network.

Or in Terminal: netsh wlan show profiles, then netsh wlan delete profile name=”NetworkName”.

Connect With a Different Account

After removing the old credential and disconnecting sessions, open File Explorer and type \\servername in the address bar. When prompted, enter the new username (for example servername\username) and password. Check Remember my credentials only on your own PC.

Sharing only works on trusted networks; see how to change a network from Public to Private in Windows 11.

Troubleshooting

Problem Fix
Old account still connects Run net use * /delete, or restart the PC
“Multiple connections to a server by the same user” error Disconnect existing sessions to that server first
Entry comes back after removal A mapped drive set to reconnect at sign-in is re-saving it; remap the drive
Can’t find the entry Check both Windows Credentials and Generic Credentials sections

Related: how to create a network drive.

Frequently Asked Questions

Is it safe to delete credentials in Credential Manager?

Yes. The worst case is being asked to sign in again. Avoid removing entries for apps you’re unsure about unless you know their passwords.

Does this work in Windows 10?

Yes, the steps are the same.

Summary

  1. Open Credential Manager > Windows Credentials.
  2. Expand the network entry and click Remove.
  3. Run net use * /delete or restart to drop cached sessions.
  4. Forget Wi-Fi networks in Settings or with netsh.