Category filter
Script to change password of a user account on Windows 10 devices
Users forgetting their device password is a common scenario for an IT admin. Hexnode lets admins to change the password of users by deploying scripts.
Jump To
Batch Script
1 |
Net user username password |
E.g., To edit the password of the user, Josh to abc_123,
Net user josh abc_123
Powershell Script
1 2 |
$NewPassword = ConvertTo-SecureString "the new password" -AsPlainText –Force Set-LocalUser -Name <name> -Password $NewPassword |
E.g., To edit the password of user, Josh to abc_123,
$NewPassword = ConvertTo-SecureString "abc_123" -AsPlainText –Force
Set-LocalUser -Name Josh -Password $NewPassword
Need more help?