Blog Post

Microsoft Entra Blog
3 MIN READ

Microsoft Entra PowerShell module now generally available

SteveMutungi's avatar
SteveMutungi
Icon for Microsoft rankMicrosoft
Jan 29, 2025

Manage and automate Microsoft Entra resources programmatically with the scenario-focused Microsoft Entra PowerShell module.

Today, we’re thrilled to announce the general availability (GA) of the Microsoft Entra PowerShell module, a new scenario-focused PowerShell module designed to streamline management and automation for Microsoft Entra. In 2021, we announced that all our future PowerShell investments would be in the Microsoft Graph PowerShell SDK. This GA milestone reflects a major step forward on this journey.

We’re grateful for the substantial feedback we’ve heard from Microsoft Entra customers about your PowerShell experiences. We'll continue to invest in the Microsoft Entra PowerShell module and expand its coverage of resources and scenarios.

What is Microsoft Entra PowerShell?

The Microsoft Entra PowerShell module is a command-line tool that allows administrators and developers to manage and automate Microsoft Entra resources programmatically. This includes efficiently managing users, groups, applications, service principals, policies, and more. The module builds upon and is part of the Microsoft Graph PowerShell SDK. It’s fully interoperable with all cmdlets in the Microsoft Graph PowerShell SDK, enabling you to perform complex operations with simple, well-documented commands. The module also offers a backward compatibility option to streamline migration from the retiring AzureAD PowerShell module. Microsoft Entra PowerShell works with Windows PowerShell 5.1 and PowerShell 7+. For the best experience on Windows, Linux, and macOS, we recommend using PowerShell 7 or later.

Benefits of Microsoft Entra PowerShell

  • Focus on usability: Microsoft Entra PowerShell offers human-readable parameters, deliberate parameter set specification, inline documentation, and core PowerShell fundamentals like pipelining.
  • Backward compatibility with AzureAD PowerShell module: Microsoft Entra PowerShell simplifies migration from the retiring AzureAD PowerShell module.
  • Flexible and granular authorization: Consistent with Microsoft Graph PowerShell SDK, Microsoft Entra PowerShell enables administrative consent for the permissions you want to grant to the application. It also supports running Microsoft Entra PowerShell using your own service principal or user-assigned managed identity.
  • Open source: The Microsoft Entra PowerShell module is open source, enabling community collaboration to enhance PowerShell and share innovations. You can explore Microsoft's customizations and adapt them to your needs.

Getting started

Installation: Install Microsoft Entra PowerShell, which uses the “/v1.0” API version to manage Microsoft Graph resources, from the PowerShell Gallery by running this command:

Install-Module -Name Microsoft.Entra -Repository PSGallery -Scope CurrentUser -Force -AllowClobber 

 

Or install the Beta module, which manages Microsoft Graph resources using the "/beta" API version, by running this command:

Install-Module -Name Microsoft.Entra.Beta -Repository PSGallery -Scope CurrentUser -Force -AllowClobber 

 

Authentication: Use the Connect-Entra command to sign in to Microsoft Entra ID with delegated access (interactive) or application-only access (noninteractive).

Connect-Entra -Scopes 'User.Read.All'

 

To see more examples for using your own registered application, Managed Identity, and other authentication methods, see the authentication scenarios documentation.

 

Find all available commands: You can list all available commands in the Microsoft Entra PowerShell module by using the command:

Get-Command -Module Microsoft.Entra*

 

Get Help: Use the Get-Help command to view detailed information about specific cmdlets, including syntax, parameters, descriptions, and examples. For instance, to learn about the Get-EntraUser cmdlet, run:

Get-Help Get-EntraUser -Full

 

Migrating from AzureAD PowerShell module: You can run your existing AzureAD PowerShell module scripts with minimal modifications using Microsoft Entra PowerShell by using the Enable-EntraAzureADAlias command. For example:

Import-Module -Name Microsoft.Entra.Users
Connect-Entra #Replaces Connect-AzureAD for auth
Enable-EntraAzureADAlias #enable aliasing
Get-AzureADUser -Top 1

Try it today!

We encourage you to try the new version and share your feedback on GitHub. Your insights are invaluable as we continue to improve and enhance the module to better meet your needs.

Learn more about Microsoft Entra PowerShell module

Explore our public documentation to learn how to install the Microsoft Entra PowerShell module, the authentication methods available, which cmdlet to use for a particular scenario, how-to guides, and more.

Check the Frequently Asked Questions (FAQs) for answers.

Thank you!

We want to thank all the community members who helped us improve this release by reporting issues on GitHub during the public preview! Please keep them coming!

 

Steve Mutungi, Product Manager, Microsoft Entra PowerShell 

 

 

Learn more about Microsoft Entra

Prevent identity attacks, ensure least privilege access, unify access controls, and improve the experience for users with comprehensive identity and network access solutions across on-premises and clouds.

Updated Jan 30, 2025
Version 3.0
  • Jan11185's avatar
    Jan11185
    Brass Contributor

    Functionality wise, how does this differ from MgGraph cmdlets?

     

     

  • It's so great to see this SteveMutungi - I’ve been following the module since its early daysback to 21/06/2023 when I was invited to the private GitHub repository long before it even reached the #Microsoft #Entra #CCP community. It’s amazing to see the module here now!

  • Congrats on the milestone! But please consider adding a proper changelog going forward :)