Microsoft 365 Error Codes

Fix Microsoft 365 Error AADSTS7000112 for Exchange Online

Bushra ParveenBushra Parveen Nov 20, 2026 868 views

Question details

Restore access to Exchange Online when the sign-in error says its application service principal is disabled.

Fix Microsoft 365 Error AADSTS7000112 for Exchange Online
Product
Microsoft 365 Exchange Online and Microsoft Entra ID
Device & OS
Windows 10 Enterprise 2016 LTSB
Scenario
A user is trying to sign in to Exchange Online in a Microsoft 365 tenant.
Observed behavior
Sign-in returns error AADSTS7000112, indicating that the Exchange Online application service principal is disabled.
Before you start

Ask a Microsoft 365 global administrator to confirm that the error identifies the Exchange Online service principal and that it was not disabled intentionally. The administrator needs access to the affected tenant and permission to manage its enterprise applications.

Solution 1Recommended

Enable the Exchange Online service principal with Microsoft Graph PowerShell

Use this method when the Exchange Online service principal is disabled in the affected tenant.

The original MSOnline PowerShell commands in older guidance use a retired module. Microsoft Graph PowerShell provides a current way to inspect and update the service principal.

1
Install the Graph module

Open PowerShell and run Install-Module Microsoft.Graph -Scope CurrentUser. Confirm the installation prompts if requested.

2
Connect to the affected tenant

Run Connect-MgGraph -TenantId '<tenant-id>' -Scopes 'Application.ReadWrite.All', replacing <tenant-id> with the affected tenant ID. Sign in as a global administrator and grant consent if prompted.

3
Check the service principal

Run $sp = Get-MgServicePrincipal -Filter "appId eq '00000002-0000-0ff1-ce00-000000000000'" -Property 'id,appId,displayName,accountEnabled', then run $sp | Select-Object Id, AppId, DisplayName, AccountEnabled. Confirm that the Exchange Online entry is present and AccountEnabled is False.

4
Enable and verify it

If the entry is disabled and you have confirmed it is safe to enable, run Update-MgServicePrincipal -ServicePrincipalId $sp.Id -AccountEnabled:$true. Then run Get-MgServicePrincipal -ServicePrincipalId $sp.Id -Property 'id,displayName,accountEnabled' | Select-Object Id, DisplayName, AccountEnabled to verify that AccountEnabled is True.

5
Retry sign-in

Return to the Exchange Online sign-in page and try signing in again. If the error persists, provide the error details and sign-in timestamp to your Microsoft 365 administrator.

Enable the Exchange Online service principal with Microsoft Graph PowerShell
If the application is not found: Check that you connected to the correct tenant and copied the application ID exactly. Do not create a replacement service principal without investigating the tenant configuration.
Free Microsoft Office alternative

Work on Office files with WPS Office while sign-in is investigated

WPS Office is a free, lightweight alternative with a familiar interface for working with Office files. Its format compatibility can make migration easier, but it does not enable Exchange Online or fix Microsoft 365 sign-in errors.

Continue working on locally available documents while an administrator investigates Exchange Online sign-in.Open and edit compatible Microsoft Office formats, including DOCX, XLSX, and PPTX.Use a familiar interface that makes switching from Microsoft Office straightforward.Install a lightweight office suite with free tools for everyday work.
microsoft office alternative - wps office

Frequently Asked Questions

What does AADSTS7000112 mean for Exchange Online?

In this scenario, the error means the Exchange Online application service principal is disabled in the Microsoft Entra tenant. An administrator can check its AccountEnabled status with Microsoft Graph PowerShell.

Who can enable the Exchange Online service principal?

A Microsoft 365 global administrator can connect to the affected tenant with Microsoft Graph PowerShell and update the service principal. The Graph session also needs the appropriate permission and admin consent.

Can I still use the Get-MsolServicePrincipal command?

The MSOnline PowerShell module used by Get-MsolServicePrincipal has been retired. Use Get-MgServicePrincipal and Update-MgServicePrincipal in Microsoft Graph PowerShell instead.

Will clearing my browser cache fix a disabled service principal?

Clearing the cache may help with browser-specific sign-in issues, but it does not enable a disabled tenant service principal. Ask an administrator to check the application's AccountEnabled status.