Allow External Senders for Selected Exchange Online Distribution Lists
Question details
Allow both internal and external senders to email only the Exchange Online distribution lists identified in a CSV file.

- Product
- Microsoft Exchange Online PowerShell
- Device & OS
- not provided
- Scenario
- An administrator needs to update sender authentication requirements for a selected set of distribution lists rather than every group in the organization.
- Observed behavior
- The intended result is that the listed distribution groups no longer require authenticated senders, while unlisted groups retain their existing settings.
Use an Exchange Online account with permission to manage distribution groups and a PowerShell session with the ExchangeOnlineManagement module installed. Prepare a CSV with an Identity column containing one target distribution group's primary email address per row, and confirm that it includes only the groups you intend to change.
Update only the distribution lists listed in your CSV
Import a defined list of group identities and disable the authenticated-sender requirement for each listed group.
The RequireSenderAuthenticationEnabled parameter controls whether a distribution group accepts messages only from authenticated senders. Setting it to $false permits unauthenticated external senders, subject to other delivery restrictions and mail-flow controls.
Create a CSV file such as C:\Temp\distribution-lists.csv with this structure: Identity sales@example.com partners@example.com Replace the example addresses with the primary email addresses of your selected distribution lists.
Open PowerShell and run: Import-Module ExchangeOnlineManagement Connect-ExchangeOnline -UserPrincipalName admin@example.com Replace admin@example.com with your administrator account and complete the sign-in prompts.
Run the following commands, replacing the CSV path if needed: $groups = Import-Csv -Path 'C:\Temp\distribution-lists.csv' $groups | ForEach-Object { Get-DistributionGroup -Identity $_.Identity -ErrorAction Stop } | Format-Table DisplayName, PrimarySmtpAddress, RequireSenderAuthenticationEnabled Confirm that every returned group is an intended target. If an identity cannot be resolved, correct the CSV and run the check again before proceeding.
After confirming the target list, run: $groups | ForEach-Object { Set-DistributionGroup -Identity $_.Identity -RequireSenderAuthenticationEnabled $false -ErrorAction Stop } This loop uses only the identities imported from your CSV. Do not replace it with an unfiltered Get-DistributionGroup pipeline, which could target every distribution group.
Run: $groups | ForEach-Object { Get-DistributionGroup -Identity $_.Identity } | Format-Table DisplayName, PrimarySmtpAddress, RequireSenderAuthenticationEnabled Confirm that RequireSenderAuthenticationEnabled is False for each target group. Then send a test message from an external mailbox to a selected list. When finished, run Disconnect-ExchangeOnline -Confirm:$false.

Prepare Your Distribution List CSV with WPS Spreadsheets
WPS Office is a free, lightweight, easy-to-use Microsoft Office alternative with a familiar spreadsheet interface and support for Excel formats, making migration straightforward. Use WPS Spreadsheets to organize group email addresses and save the Identity column as a CSV; Exchange Online PowerShell is still required to change the groups' sender settings.

Frequently Asked Questions
What column header should my CSV use?
Use Identity as the first-row header, followed by one distribution group's primary email address per row. The script reads each value through $_.Identity, so a different header requires changing that reference.
Will this command change every distribution list in my organization?
No. The provided loop runs Set-DistributionGroup only for identities imported from your CSV. Review the results of Get-DistributionGroup for those identities before applying the change, and avoid an unfiltered pipeline that retrieves all groups.
Why is external email still rejected after the setting is False?
RequireSenderAuthenticationEnabled controls authentication, not every delivery restriction. In the Exchange admin center, open Recipients > Groups, select the distribution list, and review its delivery management and moderation settings. Also check the rejection message and Exchange Online message trace for transport-rule or filtering issues.
How do I require internal senders again for the same selected lists?
Reconnect with Connect-ExchangeOnline, import the same CSV, and run: $groups = Import-Csv -Path 'C:\Temp\distribution-lists.csv' $groups | ForEach-Object { Set-DistributionGroup -Identity $_.Identity -RequireSenderAuthenticationEnabled $true -ErrorAction Stop } This requires authenticated senders for each listed group. It does not restore a mixed set of previous values unless every listed group previously used True.
Can WPS Office change Exchange distribution group settings?
No. WPS Spreadsheets can help prepare the Identity column and save it as CSV, but Exchange Online PowerShell or the Exchange admin center must apply the server-side group settings using an authorized administrator account.




