Share via

How to disable Exchange ActiveSync for users in Microsoft 365

Original KB number:   2795303


Microsoft 365 admins can use the following to disable Exchange ActiveSync access for users.

  • Exchange Online PowerShell
  • Exchange admin center

Exchange Online PowerShell

To disable ActiveSync for users by using Exchange Online PowerShell, follow these steps:

  1. Connect to Exchange Online by using remote PowerShell. For more information about how to do this, see Connect to Exchange Online PowerShell.

  2. Do one of the following:

    • To disable ActiveSync connectivity for a single user, run the following command:

      Set-CASMailbox -Identity <Mailbox ID> -ActiveSyncEnabled $False
    • To disable ActiveSync connectivity for a group of users, use the Get-User cmdlet to change the scope of the command.

      For example, to disable ActiveSync for all the users in the Sales department, run the following command:

      Get-User -RecipientTypeDetailsUserMailbox | where {$_.Department -eq "Sales"} | Set-CASMailbox -ActiveSyncEnabled $False
    • To disable ActiveSync for all users in an organization, run the following command:

      Get-Mailbox | Set-CasMailbox -ActiveSyncEnabled $False

Exchange admin center

To disable ActiveSync for users in Microsoft 365 by using the Exchange admin center, follow these steps:

  1. Sign in to the Microsoft 365 portal as a global admin.

  2. Select Admin, and then select Exchange.

  3. In the left navigation pane, select recipients, and then select mailboxes.

  4. Select the user mailbox that you want to change, and then select Edit ( ).

  5. Select mailbox features, and then select Disable Exchange ActiveSync.

    Screenshot of the Mailbox Feature dialog box.

  6. Select OK.


For more information about the Windows PowerShell cmdlets that are mentioned in this article, go to the following Microsoft TechNet websites:

Still need help? Go to Microsoft Community.