We have Office 365 account(O365) on the cloud. We have a situation where we won't be able to use O365 or EWS APIs to access some emails. So the best solution at this moment is, if possible, to forward all incoming/outgoing emails to our mail servers instantly. i.e when a user receives email on O365, a copy of that email should be forwarded to our mail servers.

Is it possible to configure such a setting so that when 0365 has incoming emails, the other mail server also receives a copy? Few seconds delay is fine.

I know this can be done per user basis where each user has to configure a forwarding email address but we wanted to do it for the whole AD accounts not for a single user.

FYI: We have to do heavy processing on each incoming emails.

  • 2
    Maybe you should be using on-premise email to begin with. It sounds like O365 is not to your benefit. – Michael Hampton Nov 22 '16 at 19:26
  • @MichaelHampton Thank you for the quick response. I'm a programmer and doing a research on it before presenting the solution to our IT dept. So the concept is somehow new to me. If I understand you correctly, Forwarding email to external server on O365 is impossible because O365 is not on-premise ? – WowBow Nov 22 '16 at 19:32
  • There might be a way to do it, it just doesn't appear to make any sense to do so. It's like going from Fairfax to Arlington by way of Seattle... – Michael Hampton Nov 22 '16 at 19:38

Configuring in bulk (via Powershell with Exchange Online for instance) mailbox level forwarding where it would deliver to both the O365 mailbox and a second mailbox elsewhere could be done...but you would need to stay on top of it for new users.

Something like:

Set-Mailbox  <Identity> -ForwardingsmtpAddress <External Recipient Email Address> -DeliverToMailboxAndForward $False

but with an array and you'd have to know the formatting of external recipient email address and it would need to be standardized (such as bob@local being forwarded to bob@external). Otherwise, the scripting would require a very large input file for both mailbox and external address.

Without doing this, what you are wanting is called "Dual Delivery" and it isn't something that O365 has available built-in even with its own transport rules.

  • Thank you for the answer. So for new users, is something that can be configured programmatically using EWS API or has to be done manually ? – WowBow Nov 22 '16 at 19:58
  • 1
    I don't mess with the EWS API too much so I don't know there...sorry. – TheCleaner Nov 22 '16 at 20:03

It doesn't sound like exchange online is doing anything to your benefit if you want to forward all email to another mail server? Why not point your MX record to the other server and cut out exchange online all together?

  • Office 365 is our main platform for mail. We were trying to set up the other mail server just for processing only so that we don't keep O365 account busy. – WowBow Nov 22 '16 at 20:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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