Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need to create lots of email aliases (more than I want to do manually), so I want to know if there's a way I can script the addition of aliases to existing mailboxes/users. I don't mind if I have to use powershell or an external tool or not.

For each existing user, I need to create a number of new email aliases.

I have, as an example:

I then want to create:


share|improve this question

When you say "alias" do you mean email address (because in Exchange parlance an alias and an email address are two different things)? If so, why not just add the email address to your Recipient Policy?


If you want to add the new email address to all users then add the email address to your existing default Recipient Policy. If you want to add the email address to a subset of users then you'll need to create a new Recipient Policy using a filter that is applicable to this subset of users (an LDAP filter based on some attribute of these users, such as department or office for example).

share|improve this answer
Good start, but the user's question is about scripting. – jgoldschrafe Sep 21 '11 at 13:17
No, it's about creating/applying an email address to a large number of users to which the OP asked if there was a way to do it via scripting. Should I not have answered because my method doesn't use scripting (but is an appropriate method because you can't just add an email address to a user account, your Exchange server must be configured to be authoratative for the email address, which is accomplished by adding the email address to the Recipient Policy)? Just because my answer doen't involve scripting doesn't invalidate it as a correct and appropriate answer. – joeqwerty Sep 21 '11 at 13:30
My fault Joe, for not making my question clearer. I've edited the question to make it clear that each person needs a number of new aliases. – Bernhard Hofmann Sep 21 '11 at 16:21
@Bernhard - I'm not sure that you're convinced, but this is the way to go. Pay special attention to the bits about "replacement strings". These are what allow you to customize the front-end of the e-mail address (rather than just the domain suffixes). – pk. Sep 21 '11 at 16:35
@Bernard: Gotcha. Thanks for the clarification. – joeqwerty Sep 21 '11 at 17:33

A few lines of powershell will do this for you:

$aliasname = Get-Mailbox -OrganizationalUnit "OUName" -ResultSize Unlimited $aliasname | Foreach-Object{ $_ | Set-mailbox -Alias }

This gets a list of all mailboxes in an OU called "OU Name" (you can change the filter to suit your needs) and then sets an alias on each these mailboxes. Obviously you can use the mailbox object to get the name, UPN etc to use as part of your alias if you wish.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.