Step 1:
The first thing you need to do is to install ExchangeOnlineManagement module for PowerShell.
Install-Module -Name ExchangeOnlineManagement -RequiredVersion 3.1.0
Installation logs..
Untrusted repository
You are installing the modules from an untrusted repository. If you trust this
repository, change its InstallationPolicy value by running the Set-PSRepository
cmdlet. Are you sure you want to install the modules from 'PSGallery'?
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help
(default is "N"):y
Installing package 'ExchangeOnlineManagement…
Step 2
Now let's connect to ExchangeOnlineManagement,
Connect-ExchangeOnline
This shall open up the web browser and ask you to log in to your Office.com account.
Once you Authenticate (may require MFA if enabled) you will see this message.
Authentication complete. You can return to the application. Feel free to close this browser tab.
And you should get a message on the console.
Let's see if we are connected to ExchangeOnline,
PS /Users/c2ctechtv> Get-OrganizationConfig | Format-Table -Auto Name, ServicePlan, TenantGuid
Name ServicePlan TenantGuid
---- ----------- ----------
code2care-xx.onmicrosoft.com BPOS_S_E15_0_Slim
If you want to disconnect with ExchangeOnline, run the below on the PowerShell Terminal.
Disconnect-ExchangeOnline
Provide Feedback For This Article
We take your feedback seriously and use it to improve our content. Thank you for helping us serve you better!
😊 Thanks for your time, your feedback has been registered!

Comments & Discussion
Facing issues? Have questions? Post them here! We're happy to help!