In Office 365, user mailboxes are tied directly to the Office 365 Exchange Online license.
Therefore, assigning an Exchange Online license to a user will automatically provision a user mailbox.
Similarly, removing the Exchange Online license will automatically remove the Exchange mailbox from the user.
This article details how you can remove an Office 365 mailbox (but still keep the user account it’s assigned to).
If you want to remove the user account as well as the Office 365 mailbox, it’s just a matter of deleting the user account. Deleting a user also removes any associated Office 365 mailbox.
How to Remove an Office 365 Mailbox Using Active Directory Users & Computers
By far, the easiest way to manage Office 365 mailboxes and licenses is using Easy365Manager.
Open up Active Directory Users & Computers, select user properties, and click the “Office 365” tab.
To remove the Office 365 license plan from the user account, clear the Exchange Online license checkbox (name may differ depending on the license plan assigned):

If you want to remove only the Exchange Online service plan, you can expand the license plan and deselect the Exchange Online service plan (only).
Please read this post if you’re unfamiliar with the difference between a service plan and a license plan.
Download a free 30 day trial of Easy365Manager here.
How to Remove an Office 365 Mailbox Using PowerShell
No matter what approach you use, removing an Office 365 mailbox is a matter of removing the Exchange Online license.
With PowerShell, the approach depends on whether you wish to
- Remove only the Exchange Online service plan, or
- Remove the entire license plan that includes Exchange Online
To remove only the service plan, you can use code similar to the following (actual code will depend on the license plan and service plans assigned):
$LO = New-MsolLicenseOptions -AccountSkuId "skrubbeltrang:EXCHANGESTANDARD" -DisabledPlans "EXCHANGE_S_STANDARD"
Set-MsolUserLicense -UserPrincipalName hans.ussing@azure.skrubbeltrang.com -LicenseOptions $LO
To remove the entire license plan containing the Exchange Online license, use code similar to this (change code according to the actual license plan):
Set-MsolUserLicense -UserPrincipalName hans.ussing@azure.skrubbeltrang.com -RemoveLicenses "skrubbeltrang:EXCHANGESTANDARD"
How to Remove an Office 365 Mailbox Using Microsoft 365 Admin
To remove an Office 365 mailbox using the Microsoft 365 Admin web console, click Users -> Active Users and select the user account:

Selecting the user account will display the user configuration.
Select Licenses and apps and deselect the Exchange Online license. This will delete the user mailbox.

How to Delete an Office 365 Mailbox Using the Azure Portal
You can also use the Azure Portal to remove the Exchange Online mailbox.
Open up Users and select the user account you wish to modify:

Click Licenses and select the Exchange Online license plan:

Then disable the Exchange Online license:

Summary
As you see, there are many different ways to accomplish this task.
Microsoft offers multiple web consoles to cover a broad range of daily tasks. With Easy365Manager, you can complete all daily tasks in one place: the Active Directory Users & Computers tool.
Using Easy365Manager will save you a lot of time and headache. Additionally, it allows you to remove your on-premise Exchange Server.
Download your free, fully functional 30-day trial here.