Effortlessly Retrieve Active Directory User Information with PowerShell
In this post, we will introduce a PowerShell script that retrieves and displays comprehensive information about users in Active Directory. Gathering user details such as email addresses, job titles, and last logon times is essential for effective user management and reporting. This script simplifies the process by pulling relevant data into a formatted table, allowing administrators to monitor user accounts efficiently. Here is the PowerShell script to retrieve Active Directory user information:
# Import the Active Directory module
Import-Module ActiveDirectory
# Retrieve all users and their relevant properties
$users = Get-ADUser -Filter * -Property DisplayName, EmailAddress, Title, LastLogonDate
# Create a report of user information
$userReport = $users | Select-Object DisplayName, EmailAddress, Title, LastLogonDate
# Output the report in a formatted table
$userReport | Format-Table -AutoSize
Write-Host "Active Directory user information retrieved successfully."Run it across your fleet
This script runs as-is on a single host. Paste it into ServerEngine to schedule it, run it on a whole server group in parallel, and keep the credentials out of the file — see the scripts documentation and the credential store.
More in Active Directory
Active Directory User Onboarding with PowerShell
2026-08-17Active Directory User Offboarding with PowerShell
2026-08-17Disable an Active Directory User with PowerShell
2026-08-17Enable an Active Directory User with PowerShell
2026-08-17Unlock an Active Directory Account with PowerShell
2026-08-17Reset an Active Directory Password with PowerShell
2026-08-17Ready when you are.
Try ServerEngine free for 7 days.