Connect to SharePoint Online using PowerShell

So you want to do some PowerShell stuff in SharePoint Online. You will need the “SharePoint Online Global Administrator” permission to perform the connection. Before we do that, lets check if we have the SharePoint Online Management Shell already installed.

1. Launch PowerShell in Administrative mode and run:-

2. If it is not listed, go ahead and download it from the PowerShell Gallery https://www.powershellgallery.com/packages/Microsoft.Online.SharePoint.PowerShell/16.0.8029.0 or if you have PowerShell 5 or newer, install the shell by running the following command:-

3. Once the SharePoint Management Shell is installed, connect to SPO by running:-

More information can be found at https://docs.microsoft.com/en-us/powershell/sharepoint/sharepoint-online/connect-sharepoint-online?view=sharepoint-ps

 

4/5 - (1 vote)

1 thought on “Connect to SharePoint Online using PowerShell”

  1. Pingback: Modify OneDrive Site Admins with PowerShell

Leave a Comment

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.

 

This site uses Akismet to reduce spam. Learn how your comment data is processed.