How to Bulk Invite Guest Users to Azure AD?

Requirement: Bulk invite guest users to Azure Active Directory.

How to invite Multiple guest user in Azure Active Directory?

In many business scenarios, you may need to bulk invite guest users to Azure AD. This means inviting a large number of guests at one time, rather than inviting them one at a time. While my other post How to invite guest users in Azure Active Directory? Explains inviting a single user to Azure AD, this post walks through the steps on how to bulk invite guest users to Azure Active Directory. We will also provide some tips on how to make the process easier. Keep reading for more information!

When you want to add users to Azure AD in bulk, there are a few different ways that you can do this. This blog post will show you two methods: using the Azure AD Portal and Azure AD PowerShell module. Let’s get started!

Bulk Add External Users to Azure Active Directory from Azure AD Portal

Guest users are people who are not affiliated with your company but need access to your company’s resources. As an Azure AD administrator, you can bulk invite guest users to your tenant. Let me show you how to bulk invite guest users to Azure AD!

  • Login to Azure Active Directory Admin Center https://aad.portal.azure.com
  • Click on “Users” >> Click on “New Guest User” from the toolbar >> Choose “Invite User” and then click on “I want to invite guest users in bulk” (You can also use “Bulk Invite” under “Bulk Activities” to invite multiple external users.)bulk invite guest users azure ad
  • From the “Bulk invite users” panel, click on “Download” button. This will download the CSV format to import bulk users from the CSV.
  • Leave the first two lines of the CSV and populate the CSV file with list of guest user Emails. Here is my populated CSV for Bulk Invite Guests how to invite guest user in office 365
  • Once populated, save and upload your CSV file and click on “Submit” button from the toolbar.Azure AD bulk import guest users from csv
  • You should see “File upload Successfully” message and wait for a moment to see “Bulk operations succeeded”. You can also use “Click here to view the status of each operation” to see the status of the bulk invite. add guest user to azure ad powershell

You can also use the “Bulk Operations” >> “Bulk Invite” from the Toolbar.

PowerShell to Bulk Add Guest Users to Azure AD

When working in the cloud, there are times when you need to add guest users to Azure AD. This can be done through the Azure portal, but what if you need to do this through PowerShell? Let me show you how to bulk invite guest users to Azure AD using PowerShell. Here is my CSV File:

powershell invite guest user azure ad
#Parameters
$SiteURL = "https://crescent.sharepoint.com/sites/marketing"
$CSVFile = "C:\Temp\GuestUsers.csv"

#Connect to Azure AD
Connect-AzureAD

#Get guest users from the CSV file
$GuestUsers = Import-CSV $CSVFile

#Iterate users and send guest and invite
Foreach($User in $GuestUsers)
{
    #Get User name and Email
    $UserName = $User.'User Name'
    $Email = $User.Email
 
    #Send invites
    Try
    {
        New-AzureADMSInvitation -InvitedUserDisplayName $UserName -InvitedUserEmailAddress $Email -InviteRedirectURL $SiteURL -SendInvitationMessage $True
        Write-Host "Invitation sent to $UserName ($Email)" -f Green
    }
    Catch
    {
        Write-Host "Error occurred for $UserName ($Email)" -f Yellow
    }
}

You can download the CSV template used in the above PowerShell from here:

Salaudeen Rajack

Salaudeen Rajack - SharePoint Expert with Two decades of SharePoint Experience. Love to Share my knowledge and experience with the SharePoint community, through real-time articles!

2 thoughts on “How to Bulk Invite Guest Users to Azure AD?

  • Is there a way to add extra fields in a bulk invite, like department, phone number, manager, etc?

    Reply

Leave a Reply

Your email address will not be published.