Open PowerShell as Administrator
Run CommandConnect-ExchangeOnline

Login with an account that has Administrative access to your Office365 tenant.

Once connected, you may need to press then type the following command to confirm that you are connected to exchange online. Get-PSSession

Run a command to test it out something like the command below
#This command will get a list of all mailboxes in the tenantGet-Mailbox

Once you are done, you can disconnect from the Session
Run CommandDisconnect-ExchangeOnline -Confirm:$false
