Back

Import Contacts to Office 365 via PowerShell

So first I had to get what fields I could import from Exchange and you can do that by logging into your Exchange Organization via PowerShell and then ...

2 min read
Published on Aug 25, 2011
Import Contacts to Office 365 via PowerShell

So first I had to get what fields I could import from Exchange and you can do that by logging into your Exchange Organization via PowerShell and then typing in the cmdlet “Get-Contact | FL” this will give you a list out of all the available fields that go with a contact. Now you can even go further and type in “Get-Contact | Export-CSV c

.csv” and it will spit it all out for to a .csv file which you can use as a template. Beware that this does also make fields that contain Office 365 specific data so you can’t use all of those fields so you’ll have to find out which ones you can’t use. _

Ready to discuss your IT needs? Please check us out for your Managed Service or Cloud Consulting needs._

1). Prepare CSV file, this file should contain all attributes you want to use for your external contact, here is the file I used.

“Name”,”ExternalEmailAddress” “Amy Smith”,”[email protected]” “Lynn McCade”,”[email protected]”

2). Create external contact using following cmdlet:

Import-Csv d:Contacts.csv|%{New-MailContact -Name $\_.Name -ExternalEmailAddress}

Great you’ve just imported your contacts now it’s time to populate the information. You can do that by creating another .csv file with the fields you got from that Get-Contact | export-csv command earlier.

1.) Make sure your CSV file is filled out properly “Name”,”MobilePhone”,”StreetAddress”,”WorkPhone” “Amy Smith”,”6198675309”,”1204 Mission Blvd.,San Diego, CA,90129”,”6198675309” “Lynn McCade”,”8588675309”,”1204 Mission Blvd.,San Diego, CA,90129”,”85886753099”

2). Set the external contact with proper attributes.

Import-Csv d:Contacts.csv|%{Set-Contact -Identity $\_.Name -MobilePhone $\_.MobilePhone -StreetAddress $\_.StreetAddress –WorkPhone $\_.WorkPhone}

Congratulations!! You’ve now imported your contacts into your GAL.

Please check us out for your Managed Service or Cloud Consulting needs.

This post has matured and its content may no longer be relevant beyond historical reference. To see the most current information on a given topic, click on the associated category or tag.

Related Posts

Understanding the GCC High Validation Process

Understanding the GCC High Validation Process

Learn how Microsoft validates organizations for GCC High, including eligibility requirements, documentation, and approval timelines for secure cloud access.

Sep 3, 2025
8 min read
Azure Backup Features and Advantages | Data Protection Guide

Understanding Azure Backup: Features and Advantage

Explore the key features and benefits of Azure Backup, including secure cloud-based recovery, policy automation, and compliance-friendly storage.

Sep 2, 2025
6 min read
How to Obtain GCC High Licenses for Your Organization

How to Obtain GCC High Licenses for Your Organization

Learn how to obtain GCC High licenses for your organization. Understand eligibility, required documentation, and Microsoft’s validation process for secure government cloud use.

Sep 1, 2025
7 min read
Top CMMC Assessment Checklist Resources

Top 7 CMMC Assessment Checklist Resources

Explore the top CMMC assessment checklist resources to prepare for compliance. Learn what tools, templates, and guides can streamline your certification journey.

Aug 28, 2025
6 min read
Cloud Backup Solutions for Microsoft 365 | Benefits & Protection

Benefits of Implementing Cloud Backup Solutions for Microsoft 365

Learn the key benefits of cloud backup for Microsoft 365, including enhanced data protection, compliance support, and recovery from cyber threats.

Aug 27, 2025
6 min read
CMMC Level 3 Security Controls: Understanding NIST 800-172

Understanding NIST 800-172 Enhanced Security Controls for CMMC Level 3

Learn how NIST 800-172 enhances CMMC Level 3 compliance with advanced security controls for protecting CUI against sophisticated cyber threats.

Aug 27, 2025
7 min read

Ready to Secure and Defend Your Data
So Your Business Can Thrive?

Fill out the form to see how we can protect your data and help your business grow.

Loading...
Secure. Defend. Thrive.

Let's start a conversation

Discover more about Agile IT's range of services by reaching out.

Don't want to wait for us to get back to you?

Schedule a Free Consultation

Location

Agile IT Headquarters
4660 La Jolla Village Drive #100
San Diego, CA 92122

Secure. Defend. Thrive.

Don't want to wait for us to get back to you?

Discover more about Agile IT's range of services by reaching out

Schedule a Free Consultation