You cannot open PowerShell directly from the Microsoft 365 admin portal. PowerShell is a task automation and configuration management framework from Microsoft, consisting of a command-line shell and the associated scripting language. To use PowerShell for managing Microsoft 365, you will need to open PowerShell on your local machine and then connect to Microsoft 365 using the PowerShell cmdlets.
Here's how you can open PowerShell on your local Windows machine:
-
Windows 10 and Windows 11:
-
Using the Search Bar:
- Click on the Start menu or press the Windows key.
- Type "PowerShell" into the search bar.
- Right-click on Windows PowerShell and select "Run as administrator" to open it with administrative privileges (recommended when managing Microsoft 365).
-
Using the Run Command:
- Press
Win + R to open the Run dialog.
- Type "powershell" and press Enter, or type "powershell" and press
Ctrl + Shift + Enter to run PowerShell as an administrator.
-
Using the Taskbar:
- If you have PowerShell pinned to your taskbar, you can right-click the icon and select "Run as administrator."
-
Windows 8 and Windows 8.1:
- Press
Win + S to open the Search charm.
- Type "PowerShell" and select Windows PowerShell from the list.
- Right-click on it and choose "Run as administrator."
-
Windows 7:
- Click on the Start menu.
- In the search box, type "PowerShell."
- Right-click on Windows PowerShell in the list and select "Run as administrator."
Once you have PowerShell open, you will need to install the required modules for Microsoft 365 and connect to your Microsoft 365 admin center with your admin credentials. Here are the general steps you would follow to connect to Microsoft 365:
- Install the Microsoft Online Service Sign-in Assistant if not already installed.
- Install the required module, which is usually the
MSOnline or Exchange Online PowerShell Module for Microsoft 365, using the PowerShell command Install-Module.
- Use the
Connect-MsolService cmdlet to connect to the Microsoft 365 service.
Always ensure you have the correct and updated modules for managing Microsoft 365, and follow the latest guidelines from Microsoft as the commands and modules can change over time.