Connect to Azure AD with PowerShell

We like to connect to Azure AD with PowerShell because we want to retrieve Microsoft 365 MFA user status. Before we can do that, we have to install Microsoft Azure Active Directory Module. In this article, we will guide you step by step.

Install module MSOnline


Start one of the above applications as administrator (high privileges). Run the command Install-Module MSOnline. Press Y and Enter.

Connect to Azure Active Directory

Run the Connect-MsolService cmdlet to initiate a connection with Azure Active Directory.


After running the above cmdlet, the sign-in window shows up.


After connecting with Azure AD, you can run your PowerShell commands.

Share :

Comments


Umesh Kumar
Umesh Kumar
18 Nov 2023 01:08 PM
test

Add New Comment

 Your Comment has been sent successfully. Thank you!   Refresh
Error: Please try again