Change an Incorrect Microsoft 365 Username or User Principal Name
Question details
The user needs to remove unwanted numbers from a Microsoft 365 sign-in name by changing the user's principal name.

- Product
- Microsoft 365
- Device & OS
- not provided
- Scenario
- An administrator wants to correct a user's Microsoft 365 username.
- Observed behavior
- The current username contains unwanted numbers.
Sign in with an administrator account that can manage the target user, and confirm that the desired domain is verified in Microsoft 365. Check whether the account is synchronized from on-premises Active Directory, because synchronized accounts must generally be changed at the source.
Change the username in the Microsoft 365 admin center
Use the admin center to correct the sign-in name of a cloud-managed user.
Sign in to the Microsoft 365 admin center at admin.microsoft.com, then select Users > Active users.
Choose the user whose username contains unwanted numbers. On the account panel, select Manage username and email.
Edit the username, select an available verified domain if needed, and save the changes. The new sign-in name must not already be in use.
Provide the user with the new username and have them use it to sign in to Microsoft 365. Check the account details in Users > Active users to confirm the change.

Change the user principal name with Microsoft Graph PowerShell
Use Microsoft Graph PowerShell when you prefer a command-line method for a cloud-managed account.
Work on Office files with WPS Office
WPS Office is a free, lightweight alternative with a familiar interface and support for Microsoft Office formats, making it easy to move existing documents. It does not change or repair Microsoft 365 usernames.

Frequently Asked Questions
Can I change a Microsoft 365 username without PowerShell?
Yes. In the Microsoft 365 admin center, go to Users > Active users, select the account, and choose Manage username and email.
Why can't I use the username I want?
The new sign-in name must be unique, and its domain must be verified in the Microsoft 365 tenant. Check for an existing account using the same name and review the domain in the admin center.
What if the user is synchronized from on-premises Active Directory?
Change the user principal name in the on-premises directory, then allow Microsoft Entra Connect or your synchronization service to sync the change to Microsoft 365.
Does changing the user principal name automatically change the email address?
Not necessarily. A user principal name is a sign-in identifier, while mailbox addresses are managed separately. Review the user's email addresses in the admin center after making the change.
Why does Set-MsolUserPrincipalName no longer work?
The command belongs to the retired MSOnline PowerShell module. Use the Microsoft 365 admin center or connect with Microsoft Graph PowerShell and run Update-MgUser instead.




