Why Do I Keep Getting Microsoft Verification Codes?
In this article
You keep getting Microsoft verification codes because someone (or something) is trying to sign in to your Microsoft account, or because you (or a device you own) triggered a sign-in prompt that you didn't notice. The codes are sent to your recovery email or phone as part of Microsoft's two-step verification. If you didn't request the code, it usually means an attacker is attempting to access your account, or your own device is repeatedly trying to authenticate. The fix is to secure your account immediately, change your password, and review your recent activity. Below is a step-by-step guide to stop the unwanted codes and protect your account.
What You'll Need
- Access to the email address or phone number that receives the codes
- A device with a web browser (phone, tablet, or computer)
- Your Microsoft account password (if you remember it) or access to a recovery method
Step-by-Step
- Check the sender and the code format. Genuine Microsoft verification codes come from the sender "Microsoft account team" and are 7 digits. If the sender is different, or the code is longer/shorter, it might be a phishing attempt. Do not reply to the message or click any links inside it.
- Sign in to your Microsoft account on a trusted device. Go to account.microsoft.com and sign in with your password. If you can't sign in, use the "Forgot password" link to reset it via your recovery email or phone.
- Review your recent activity. After signing in, go to the Security section (look for "Security" or "Security dashboard"). Click on "Recent activity" to see all sign-in attempts. Look for any that you don't recognize—especially from unusual locations, devices, or IP addresses.
- Change your password immediately. In the Security section, choose "Change my password." Use a strong, unique password that you haven't used elsewhere. Avoid common words, birthdays, or simple patterns. If you suspect someone else knows your password, change it right away.
- Turn on two-step verification (if not already on). Under "Security" or "Advanced security options," find "Two-step verification" and turn it on. This adds an extra layer: even if someone gets your password, they can't get in without the code sent to your trusted device.
- Check your security info. In "Advanced security options," review the phone numbers and email addresses listed as recovery methods. Remove any that you don't recognize. If an attacker added their own, removing it stops them from receiving codes.
- Sign out of all devices. In the Security section, look for "Sign out everywhere" or "Sign out of all devices." This forces any session an attacker might have open to end. You'll have to sign in again on your own devices.
- If codes keep coming after you've secured your account, check for a stuck sign-in loop. Sometimes your own device (like an old phone or a game console) has stored your password and keeps trying to sync. Sign out of that device and sign back in with your new password. If you can't find the device, change your password again—that will stop it.
Common Mistakes
- Ignoring the codes. If you ignore them, the attacker may keep trying. Always take action, even if the codes are annoying.
- Sharing the code with anyone. Microsoft will never call or text you asking for a verification code. If someone asks for it, it's a scam.
- Using the same password on other sites. If you reuse your Microsoft password elsewhere, a breach on another site could give attackers your password. Always use a unique password for your Microsoft account.
- Not checking the "Recent activity" section. This is the fastest way to see if someone is actually trying to get in. Skipping it leaves you guessing.
- Turning off two-step verification to stop the codes. That's the opposite of what you want—it makes your account less secure and doesn't stop the attempts.
Tips
- Use an authenticator app instead of SMS. In "Advanced security options," you can add the Microsoft Authenticator app. It generates codes that don't rely on your phone number, which is more secure and often less annoying.
- Set up a recovery email that you check often. Make sure the recovery email is one you use regularly, so you notice if a code arrives that you didn't request.
- Enable passwordless sign-in. Microsoft offers a passwordless option where you approve sign-ins from the Authenticator app instead of entering a password. This eliminates the password-based attacks that cause these codes.
- Keep your devices updated. Outdated devices may have security flaws that make it easier for attackers to hijack your session. Update your phone, computer, and apps regularly.
Troubleshooting
If the codes keep coming even after you've changed your password and signed out everywhere:
- Wait 24–48 hours. Some sign-in attempts are automated and may continue for a short time after you've secured your account. They usually stop once the attacker realizes they can't get in.
- Check for malware. Run a full antivirus scan on your computer and phone. Malware could be stealing your credentials or triggering sign-in attempts from your device.
- Remove unrecognized apps. In your Microsoft account, go to "Privacy" > "Apps and services" and revoke access for any app you don't recognize. An app might be trying to sign in with your stored credentials.
- Contact Microsoft support. If the codes persist for more than a week, visit support.microsoft.com and chat with a support agent. They can investigate whether your account is under a targeted attack.
Frequently Asked Questions
Why am I getting verification codes but no one is trying to sign in?
It could be your own device—like an old phone or a game console—that has your password saved and is trying to sync. Sign out of that device or change your password to stop it.
Can someone get my verification code without my phone?
If your phone number is not linked to your account, they can't. But if they've added their own recovery method, they might. That's why you should check your security info and remove any unknown phone numbers or emails.
What if I never set up two-step verification?
Microsoft may still send codes if they detect a suspicious sign-in attempt. That's a security feature. If you haven't set up two-step, you can turn it on to have more control.
Should I reply to the text to stop it?
No. Replying to a verification code text is never necessary. Just delete the message. If you reply, you might confirm your number is active, which could lead to more spam.
Will changing my password stop the codes?
Usually yes, because the attacker no longer has the correct password to trigger the sign-in prompt. If it doesn't stop, check for a stuck device or malware.
Is it safe to ignore the codes if I didn't request them?
It's not safe to ignore them indefinitely. Even if you didn't request them, someone is trying to get in. Secure your account as described above, then ignore future ones that come after you've secured it.