EASYENTRA Blog

News & Updates

How to Export a Private Channel Membership Report in Microsoft Teams

How to Export a Private Channel Membership Report in Microsoft Teams

Private channels allow selected members of a team to collaborate in a restricted space. Unlike standard channels, membership is managed separately, and only users added to the private channel can access its conversations and files.

As the number of teams increases, keeping track of private channel members and owners can become difficult. A private channel membership report helps administrators review who has access, identify channels without enough owners, and remove users who no longer require access. This guide explains how to get private channel membership details in Microsoft Teams.

How to List Private Channel Members in Microsoft Teams

The best way to review private channel membership depends on how much information you need. For a quick check of a specific channel, the Teams admin center is usually enough. However, when the review involves multiple teams or the entire tenant, PowerShell offers a faster and more practical approach. Let’s look at both options.

View Private Channel Membership in the Teams Admin Center

The Microsoft Teams admin center provides a graphical way to review private channels and their members.

  1. Sign in to the Microsoft Teams admin center.
  2. Go to Teams > Manage teams.
  3. Select the team you want to review.
  4. Open the Channels tab to view the channels associated with that team.
  5. Filter Type = Private to display only private channels.
  6. Select a private channel to review its members and owners.

This method works well when you need to inspect a single team or channel. However, it becomes time-consuming when you need to review private channel membership across multiple teams because each team must be checked separately.

Export Private Channel Membership Report in MS Teams Using PowerShell

The following script scans every Microsoft team in the tenant, identifies its private channels, and retrieves the members and owners assigned to each channel.

# 1. Clear out any previous script data
$Report = @()
# 2. Retrieve all teams from the tenant
Write-Host "Fetching all teams from the tenant..." -ForegroundColor Cyan
$AllTeams = Get-Team
# 3. Loop through each team
foreach ($Team in $AllTeams) {
    Write-Host "Checking Team: $($Team.DisplayName)" -ForegroundColor Yellow
    # Get only the private channels for this team
    $PrivateChannels = Get-TeamChannel -GroupId $Team.GroupId -MembershipType Private
     foreach ($Channel in $PrivateChannels) {
        Write-Host "  --> Found Private Channel: $($Channel.DisplayName)" -ForegroundColor Green
           try {
            # Attempt to gather members
            $Members = Get-TeamChannelUser -GroupId $Team.GroupId -DisplayName $Channel.DisplayName -ErrorAction Stop
                  if ($null -eq $Members -or $Members.Count -eq 0) {
                # Logs the channel even if empty or orphaned
                $Report += [PSCustomObject]@{
                    TeamName           = $Team.DisplayName
                    TeamGroupId        = $Team.GroupId
                    PrivateChannelName = $Channel.DisplayName
                    ChannelId          = $Channel.Id
                    MemberName         = "NO ACTIVE MEMBERS / ORPHANED"
                    MemberUPN          = "N/A"
                    ChannelRole        = "N/A"
                }
            } else {
                # Logs each member found
                foreach ($Member in $Members) {
                    $Report += [PSCustomObject]@{
                        TeamName           = $Team.DisplayName
                        TeamGroupId        = $Team.GroupId
                        PrivateChannelName = $Channel.DisplayName
                        ChannelId          = $Channel.Id
                        MemberName         = $Member.Name
                        MemberUPN          = $Member.User
                        ChannelRole        = $Member.Role
                    }
                }
            }
        } catch {
            # Logs the channel if an access/permission error occurs
            $Report += [PSCustomObject]@{
                TeamName           = $Team.DisplayName
                TeamGroupId        = $Team.GroupId
                PrivateChannelName = $Channel.DisplayName
                ChannelId          = $Channel.Id
                MemberName         = "ERROR FETCHING MEMBERS"
                MemberUPN          = $_.Exception.Message
                ChannelRole        = "ERROR"
            }
        }
    }
}
# 4. Export results to CSV
if ($Report.Count -gt 0) {
    $OutputPath = "$env:USERPROFILE\Desktop\Teams_Private_Channel_Membership.csv"
    $Report | Export-Csv -Path $OutputPath -NoTypeInformation -Encoding UTF8
    Write-Host "`n[SUCCESS] Report saved to: $OutputPath" -ForegroundColor Green
} else {
    Write-Host "`n[INFO] No private channels were discovered." -ForegroundColor Cyan
}

The report provides more than a list of private channel members and owners. It also helps identify orphaned private channels with no active members or owners. These channels are clearly marked as No active members/Orphaned, so administrators can quickly find channels that may no longer be in use and decide whether they should be reviewed, reassigned, or removed.

Each private channel uses a dedicated SharePoint site to store its files, so reviewing channel membership also helps ensure that only the right users can access its documents. 

Running this report periodically can help administrators remove outdated access, address ownership gaps, and maintain better control over private channel data! 

Free 30-minute demo

try 30 days for free

GET EASYENTRA NEWS

Opt out at any time

“One of the best products I've used.”
Gary Shurland
Chief Information Officer, Mirick, United States
“This tool has been invaluable in streamlining our IT processes.”
Tyson Mckay
Chief Information Officer, Southwest Network, United States
“EasyEntra includes offboarding steps we’d never even thought of, like removing inbox rules.”
Jerry Jacobson
IT Operations Manager, MetalTek International, United States
“This product has been a miracle for our Help Desk. EasyEntra has completely transformed how we handle Microsoft 365 administration.”
Doug Sanders
Manager of Technical Customer Support, Junior Achievement USA, United States
“Your product is such a time saver. I love it!”
Scott Fehr
IT Infrastructure, MEC Aerial Work Platforms, United States
“It's a good product and saves us lots of time for these ongoing quick admin tasks.” 
Chris McFerran
Managing Director, CTech IT Solutions Ltd, United Kingdom
“The speed of creating a user is magic.” 
John Duncan
IT Administrator, MetalTek International, United States
“EasyEntra has significantly streamlined our workflow, simplifying everything. It feels almost like a revolution.”
Johan Sadelius
IT-chef, Arjeplog Kommun, Sweden
I greatly appreciate your assistance and willingness to enhance the already outstanding product.”
Michael I. Wilson
Executive Director of Information Technology, Archdiocese Of Washington, United States
“It's great not having to switch back and forth between the O365 admin center and the Teams admin center to assign groups. I am sold!”
Thomas Madden
Director Information Technology, AutoPayPlus, United States
“I would highly recommend organizations use the solution as it greatly simplifies various tasks.”
S. Roger Singh
Chief Technology Officer, Prasad & Company LLP, Canada
“EasyEntra is time-saving. Love the copy/paste for user/computer groups and the copy to new user.”
Damian Nita
Associate Network Administrator, Shenandoah Valley Westminster-Canterbury, United States
“EasyEntra has transformed our daily IT operations by simplifying user management, reducing errors, and enhancing overall efficiency.”
Henrik Nefling
IT- and Digitalization Manager, Animal Protection Denmark, Denmark