In this blog we will talk about how to Install Exchange online PowerShell module using quick simple commands.
Exchange online PowerShell module is required to connect to Exchange online using Windows PowerShell.
To Install Exchange Online PowerShell module you have to run Install-Module -Name ExchangeOnlineManagement -Force command, in the Windows PowerShell and it will install the latest version of it.
Steps to Install Exchange online PowerShell module
Windows PowerShell should be ran as an Administrator, otherwise it will not allow us to install the module.
Once the PowerShell is opened, You will first have to set the execution policy to remote signed, to allow the installation:
To set the execution policy run: Set-ExecutionPolicy RemoteSigned -Scope CurrentUser
Once prompted, type A and hit enter, as seen in the image above.
Now you simply have to run the command, Install-Module -Name ExchangeOnlineManagement -Force
If you run it without the -Force parameter, then it will prompt you to approve the installation, you can do the same by entering A or Y.
Once the install is completed, we will have to import the module by running the command, Import-Module ExchangeOnlineManagement
All these commands, should be ran in the same PowerShell Window.
Once the import is completed, you can connect to Exchange Online by running the command, Connect-ExchangeOnline
You will be then prompted to login with your Exchange Admin or Global admin account.
Once you have entered the email and the password of the required admin account, if it is connected to the exchange online it will show you the below screen or go to the next line without any error:
In this way you can easily Install Exchange online PowerShell module on a windows PowerShell to be able to connect to exchange online.
Once you are connect to exchange online you can run all the exchange related PowerShell commands.
Useful links
How to Permanently Delete User Account without PowerShell in Office 365
How to Export Current mailbox sizes report in Office 365 without PowerShell
Microsoft Official Article for the same
How to Enable Organization Customization without PowerShell
Date: 13/09/2023
Author: Prem