Single-use codes let you avoid using your password when you sign in to a public computer or other not-quite-secure device.
When you want this extra security, you request a code from the sign-in screen. We send you the code in a text message, and then you use that code to sign in instead of your regular password, that one time.
Sorry, this service isn’t available in all regions.
To get and use a single-use code
- Go to the Microsoft website you want to sign in to, like Outlook.com, OneDrive, Xbox.com, Office Online, Microsoft account, or others.
- When you're asked to sign in, click Sign in with a single-use code.
- Enter the email address and mobile phone number associated with your Microsoft account. If you haven't added a mobile phone number to your account yet, learn how to add one here: Security info & security codes.
- Click Text me the code.
- You’ll get your code within a few minutes. If you’ve waited more than 15 minutes, click Don’t have a code? to request another one.
- Enter the code in the Single-use code box, and then click Sign in.
If your code doesn't work, request a new code. If you requested more than one code, use the most recent one. To prevent abuse of Microsoft services, we limit the number of times you can request a code each day.