Applies to Microsoft Exchange 2013, Exchange 2010, Office365 Exchange
Outlook isn't alone in supporting photos, in fact, the Active Directory has supported pictures for years, using the Picture attribute (thumbnailPhoto) to store thumbnail photos, and in Exchange 2010 and on-premise Exchange 2013, Import-RecipientDataProperty cmdlet makes it easy to import photos.
The photos should be under 10K in size and re-sized to approximately 100x100 pixels. While the thumbnailPhoto property can support up to 100K files, the RecipientDataProperty cmdlet can only import up to 10K. Generally speaking, because the GAL can only display small thumbnails, the images can be reduced to about 3K and still look good.
The OWA Address book will display the images almost immediately but it can take up to 24 hours for the images to show up in the GAL in Outlook.
To import a single contact, the cmdlet will look like this:
Import-RecipientDataProperty -Identity "full name" -Picture -FileData ([Byte[]]$(Get-Content -Path "C:\photos\firstlast.jpg" -Encoding Byte -ReadCount 0))
You can bulk import using a list in a CSV or text file.
In addition, you can use Import-RecipientDataProperty to import audio files for name pronunciation.
Import-RecipientDataProperty -Identity maryc -SpokenName -FileData ([Byte[]]$(Get-Content -Path "C:\AudioFiles\maryc.wma" -Encoding Byte -ReadCount 0))
Office365
To import contact photos into Office365 (or Exchange 2013), you need to use the Set-UserPhoto cmdlet to upload and then save the photo.
Set-UserPhoto "First Last" -PictureData ([System.IO.File]::ReadAllBytes("c:\photos\firstlast.jpg"))After importing the photos, you need to use this cmdlet to save the photo with the contact.
Set-UserPhoto "First Last" -Save
To remove a photo from a user account, use the Remove-UserPhoto cmdlet:
Remove-UserPhoto "First Last"
Note: you can use email address, alias, or first last (full name) as the username.
It will take up to 24 hours for the images to show up in the GAL in Outlook. The OWA Address book will display the images almost immediately.
Bulk import
To bulk import photos, you need a CSV file with the username and photos:
Identity, PictureData EMO, I:\Import\emo.png sue@cdolive.com, I:\Import\sue.jpg kens, I:\Import\kens.png
And the Set-UserPhoto cmdlet to upload and save the photos:
Import-Csv I:\Import\import.csv |%{Set-UserPhoto -Identity $_.Identity -PictureData ([System.IO.File]::ReadAllBytes($_.PictureData))}
Import-Csv I:\Import\import.csv |%{Set-UserPhoto -Identity $_.Identity -Save}
To remove contact photos, use the Remove-UserPhoto cmdlet:
Import-Csv I:\Import\import.csv |%{Remove-UserPhoto -Identity $_.Identity} | Tools | |
|---|---|
AD Photo Edit is a user friendly (and free) program for adding, removing and editing these images.If you are using Outlook 2010 then you have probably noticed the ability for Outlook to display an image/photo for each user or contact in your Active Directory domain. However, the only method that MS provide you with for actually importing images into the AD attribute that Outlook 2010 pulls these images from is a powershell cmdlet that comes with Exchange 2010. This cmdlet also limits you to selecting images that are less than 10 KB even though the thumbnailPhoto attribute in AD is only limited to 100 KB. | |
CodeTwo Active Directory Photos will let you upload photographs to Active Directory and manage them easily using a light and intuitive user interface. This freeware application has been designed to make managing scores of users' images straightforward and fast. | |
Outlook Photos from Exclaimer makes it easy to add user photos to your Microsoft Exchange 2010 global address list (GAL). Like Contact and Social Connector photos, GAL photos display on contacts and email messages associated with that user. Free. | |
More Information
Import-RecipientDataProperty (TechNet)
Set-UserPhoto (TechNet)
Batch Import Photos into Outlook Contacts

