What to do first when a Microsoft 365 account is compromised
When a Microsoft 365 account is compromised, contain it before you investigate. Disable the account or reset the password, revoke its sessions, remove sign-in methods you do not recognize, then look for the forwarding and inbox rules an attacker leaves behind.
The first steps
Do these in order. They follow Microsoft’s guide, Respond to a compromised email account in Microsoft 365, which has the exact clicks and commands.
1. Disable the account.
Microsoft calls disabling the account preferred and highly recommended until the investigation is done. If you cannot disable it, reset the password. Do not email the new password, because the attacker may be in the mailbox. A password reset does not revoke app passwords, so delete them. Microsoft Learn: Respond to a compromised email account
2. Revoke all sessions.
This invalidates the user’s refresh tokens. Microsoft says access tokens last 1 hour by default, so access can continue until the token expires. Microsoft Learn: Revoke user access in an emergency
3. Check the registered MFA methods.
Remove any method you do not recognize, because an attacker may have added one. Microsoft Learn: Manage authentication methods
4. Review app consent and admin roles.
Remove apps the user consented to that should not have access, and any admin roles the user should not hold.
5. Find forwarding and inbox rules.
Check the mailbox for forwarding to other addresses and for inbox rules, including hidden ones, that forward or redirect mail. Microsoft lists rules that send mail to unknown addresses, or move it to folders such as Junk Email, as signs of compromise. Microsoft Learn: Respond to a compromised email account
6. Read the sign-in and audit logs.
Look at IP address, location, time and success or failure, starting before the first suspicious activity. Search for the same pattern on other accounts, because it can mean more than one is compromised. Microsoft Learn: Sign-in logs
7. Clean up when you are done.
If you disabled the account, reset the password and then enable it. If the mailbox sent spam, Microsoft says it may be blocked from sending, and you remove it from the Restricted entities page. Microsoft Learn: Respond to a compromised email account
Doing it with Avvi
Avvi’s help article follows the same idea: contain first, investigate second. Each request is asked in chat, and Avvi asks for a Yes or No before it changes anything.
- Ask Avvi to reset the password, and answer yes when it asks whether to sign the person out everywhere. Then ask for their sessions to be revoked as a separate request, and read the reply to confirm it says sessions were revoked.
- An MFA reset tries to revoke sessions only when it actually removed a method, and that attempt can fail, so do not rely on it for revocation.
- Ask for the inbox rules and forwarding status on the mailbox, then for a security investigation on the person. It runs ten checks and reports what it checked and what it skipped.
- A skipped check means unknown, not clean. On a client without Microsoft Entra ID P1 or P2, the sign-in and risk checks cannot run.
- Containment stops what happens next. It does not bring back mail sent while the intruder had access.
See An account may be compromised. What do I do first?, Sign a user out of everywhere and Check whether a user’s sign-ins look suspicious. You can also look at the Avvi platform.
Questions people ask
Should I disable the account or only reset the password?
Disable it if you can. Microsoft calls disabling the account preferred and highly recommended until you finish the investigation, and says to reset the password if you cannot disable it. Microsoft Learn: Respond to a compromised email account
Does revoking sessions sign the attacker out right away?
Not always. Microsoft says access tokens last 1 hour by default, so a session can continue until its token expires. Microsoft Learn: Revoke user access in an emergency Avvi’s help article says to wait a few minutes, then check that the person is really signed out.
What does a risky user flag mean?
It is Microsoft’s verdict, not Avvi’s: Microsoft saw something it links to compromise. Treat it as a reason to look. Microsoft says full Microsoft Entra ID Protection features need a Microsoft Entra ID P2 or Microsoft Entra Suite license. Microsoft Learn: What is Microsoft Entra ID Protection?
Updated Nov 2026
Related
See these requests run in chat
Book a walkthrough and watch Avvi handle everyday Microsoft 365 requests, with every change confirmed and logged.