Skip to content
Follow
Windows

How to Change Windows 11 Password via Command Prompt

Richard
Written by
Richard
Jan 2, 2022 Updated Jul 14, 2026 3 min read
How to Enable or Disable Microsoft Defender Cloud Protection
How to Enable or Disable Microsoft Defender Cloud Protection

Changing your Windows 11 password using the Command Prompt is a direct way to manage your account security.

The Command Prompt, or CMD, is a tool that lets you type commands to tell Windows what to do. This method lets you change your password without using the usual Settings app.

You can use the `net user` command in Command Prompt to quickly reset a forgotten password or set a new one. For example, the command `net user yourusername NewPassword` directly changes your password.

This is helpful if you need to update your password quickly or if you can’t remember your old one and need to get back into your account.

⚡ Quick Answer

Open Command Prompt as administrator, then type “net user USERNAME *” and press Enter. Replace USERNAME with your actual account name. You will be prompted to enter and confirm your new password.

Changing Your Password via Windows Settings

You can change your Windows 11 password using the built-in Settings app. This method works for both Microsoft accounts and local accounts on your computer. Open Settings, navigate to Accounts, then Sign-in options, select Password, and click Change to follow the steps.

  1. Open the Start menu and click the Settings gear icon.
  2. Select Accounts from the left sidebar.
  3. Click on Sign-in options.
  4. Choose Password and click the Change button.
  5. Follow the on-screen prompts to verify your identity and set a new password.
Searching and opening Windows Terminal in Windows 11
windows terminal search and open

Microsoft Account vs. Local Account

Knowing your account type is important. A Microsoft account links to your email and syncs settings across your devices; password changes happen through the official Microsoft online portal. A local account is unique to your specific computer.

Changing Password via Command Prompt (Admin Required)

Changing your Windows 11 password with the Command Prompt is a quick way to update it if you have administrator access. First, open Command Prompt as an administrator. Then, type ‘net user’ to see your username, and finally use ‘net user USERNAME *’ to set a new password for that user.

To run Command Prompt as an administrator in Windows 11, search for ‘Command Prompt’ in the Start menu, right-click the result, and select ‘Run as administrator.’ This grants the necessary permissions for system-level changes.

2. To see your user list, type the following command:

💻Code
net user
Listing users in Command Prompt on Windows 11
windows list users command prompt

3. Then, to change a specific user’s password, enter this command and press Enter:

💻Code
net user USERNAME *
Successfully changed user password in Windows 11
successfully changed user password windows 11

Changing Password via PowerShell (Admin Required)

You can change your Windows 11 password using PowerShell if you have administrator privileges. Open PowerShell as an administrator, then use the ‘Get-LocalUser’ command to see your account. After that, you’ll create a secure password variable and apply it to update your account’s password.

  1. Open PowerShell as an administrator.
  2. View your local users with this command:
PowerShell
Get-LocalUser
Listing users using PowerShell in Windows 11
windows 11 list users powershell

3. Create a secure password variable and apply it to your account:

PowerShell
$Password = Read-Host "Enter the new password" -AsSecureString

4. Use these commands to finalize the change:

PowerShell
$UserAccount = Get-LocalUser -Name "USERNAME"
$UserAccount | Set-LocalUser -Password $Password

Summary

You can change your Windows 11 password using the Settings app for simplicity, or Command Prompt and PowerShell for faster administrative control.

Can I change my 🪟 Windows 11 password without knowing the old one?

If you’ve forgotten your Windows 11 password, you can’t change it directly; instead, you must use the ‘I forgot my password’ option on the sign-in screen to reset it.

Is it safer to use a PIN or a password in 🪟 Windows 11?

Using a PIN for your Windows 11 login is generally safer than a password because it’s tied to your device and stored securely, making it harder to steal remotely.

Was this guide helpful?

Tags: #Windows 11
Was this helpful?
Richard

About the Author

Richard

Tech Writer, IT Professional

Richard, a writer for Geek Rewind, is a tech enthusiast who loves breaking down complex IT topics into simple, easy-to-understand ideas. With years of hands-on experience in system administration and enterprise IT operations, he’s developed a knack for offering practical tips and solutions. Richard aims to make technology more accessible and actionable. He's deeply committed to the Geek Rewind community, always ready to answer questions and engage in discussions.

📚 Related Tutorials

How to Create a Password Reset Disk in Windows 11
Windows How to Create a Password Reset Disk in Windows 11
How to Reset Your Microsoft Account Password
Windows How to Reset Your Microsoft Account Password
How to Change or Reset Your Windows 11 Password
Windows How to Change or Reset Your Windows 11 Password
How to Change your Microsoft Account Password
Windows How to Change your Microsoft Account Password

No comments yet — be the first to share your thoughts!

Leave a Comment

Your email address will not be published. Required fields are marked *