Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

How do I set up an Office 365 email account for Jira Service Desk

We have created a Jira SD project and want to associate an external email with the project.  We've navigated to Project Settings -> Email Requests and tested the work flow with the built in Atlassian email and the flow works.  But now we want to add a custom email address and here lies our problem. 

Background details on the email:

Microsoft Office 365 
NOT a shared mailbox, it's a regular user
We've tested to make sure someone can login to the account from a browser 

When we navigate to Project Settings -> Email Requests -> Add a custom email address and fill in the appropriate settings, we can't get Jira to connect to the email.  We've worked with our IT and tried over  20 combinations of protocols (POP3, iMAP, etc) with numerous port settings (both the defaults and the ones recommended by Microsoft).  We've read through documentation, read posts on the net, but we can't find a resolution.  

Some of the error messages we've received:

Authenticate failed
No login methods supported 
Logon failure unknown user name or password
Command is not valid in this state
Timeout trying to reach server

Our IT is just as baffled as we are, we never expected this to be an issue in setting up a new Service Desk project.  What else can I provide to help us solve what should be a relatively simple set up?


9 answers

1 accepted

12 votes
Answer accepted

I've had lots of "fun" getting incoming IMAP and outgoing SMTP to work using the one mailbox, finally there. I know I'm not answering every question above, but hope my findings can help. Obviously replace 'fake', 'tenant', and 'domain' with your real ones.

-Must not be a shared mailbox

-Before you do anything in Jira, sign in to the damn mailbox in OWA and make sure it actually works just as a mailbox. Any problems you have at this point are for Microsoft Support/Forums. Don't forget to test both directions internally and externally

-Incoming Mail IMAP settings:
Host Name:
Port: 993

-Outgoing mail SMTP settings:
From address:
Protocol: SMTP
Hostname: (replace this with the MX endpoint for your O365 tenant, always ends with "")
SMTP Port: 25
TLS: Yes
Username: fake

I hate to necro this but I've seen other recent posts on this thread and wanted to say that this was the solution for me.  Easy and simple using these configuration settings, thanks!

Like # people like this

I'm going to add as well that after migrating to Office 365, we were unable to see Full Name of user who triggered a Jira notification, and this comment helped resolve the issue as well!

We were using

Host name:

SMTP Port: 587


Emails came in, but just said "JIRA" for all of them. After updating the port to Peter's suggestion above as well as the Hostname, now the emails are displaying the full name of user.


Like # people like this

We banged our heads against a wall with all possible combinations, and in the end, realized that we were referencing our tenant, when it should have been:
SMTP: 587
username + password

Hey, i also ended up here because of a strange behavior. I managed to get jira to send mails from But i want the servicedesk to send it from When i try to send my queue in the logs it says: 
SMTPSendFailedException: 554 5.2.252 STOREDRV.Submission.Exception:SendAsDeniedException.MapiExceptionSendAsDenied; Failed to process message due to a permanent exception with message Cannot submit message

Anyone has solved this? When i set servicedesk to send it from it works fine but on it refuses to send anything. I tried the following mailservers: (tenant was my domain though)

None of them solved the problem. 

We just solved this by allowing outgoing traffic on port 993 to the outlook ip ranges as listed in this microsoft article:

Jack Brickey Community Leader Aug 24, 2018

Thanks for sharing here @Allan Libby

Like Dane Lewin likes this

Jack, thanks for your reply. I'll test it soon, I'm currently on holiday.

Newbie here I am just setting our company emails but it says you have to verify your domains in Jira.  Assuming that people with issues had done this ?

Office 365. Local firewall ports are irrelevant. Office 365 also supports IMAPS out of the box. Since we use SSO and MFA I created an APP password for our service account and we always get Authentication errors. We have used this same setup with other providers without issue.

I had the same problem and none of the answers above helped me.

I verified that my jira server had port 993 access to O365, so that wasn't the issue. The test email from jira went through when the email settings were entered, so I knew that wasn't an issue.

It turned out to be something silly in the scheme of things - under "Global Mail Settings" in the System configuration, "Email puller" and "Email processor" were both turned off.

Within a few minutes of enabling these, the incoming mail was parsed by Jira and added into the queue as I expected.


0 votes

Not all 0365 accounts enable IMAP access.

Hello Matt,thanks for your quick reply. I already checked if IMAP is enabled, it is. And of course I tried POP and SMTPI tried to send a mail via Jira, I get an authentication error. Interesting is the DEBUG

Message at the end:DEBUG SMTP: need username and password for authentication
DEBUG SMTP: protocolConnect returning false,, user=jira, password=<null>


Why "user=jira" and pass "null"?


Check my attachemts, I inserted the correct credentials.


Here is the complete log:

An error has occurred with sending the test email:
com.atlassian.mail.MailException: com.sun.mail.util.MailConnectException: Couldn't connect to host, port:, 25; timeout 10000;
  nested exception is: Verbindungsaufbau abgelehnt

DEBUG: getProvider() returning javax.mail.Provider[TRANSPORT,smtp,com.sun.mail.smtp.SMTPTransport,Oracle]
DEBUG SMTP: need username and password for authentication
DEBUG SMTP: protocolConnect returning false,, user=jira, password=<null>
DEBUG SMTP: useEhlo true, useAuth true
DEBUG SMTP: trying to connect to host "", port 25, isSSL false


Shouldn't your SMTP be a gateway host on your network, not office365 domain?

I had similar issues connecting JIRA to O365 and it turned out to be a security policy.  When I requested the mailbox to be created, I had to specify I needed it to be imaps (secure IMAP enabled) so they would add the account to the correct exception group.

Those are the exact settings I have as well.  I am asking our host to make sure port 993 is allowed out to the microsoft IP range.

Same problem here and only with o365. Atlassian plz help!

We are still trying to get time with our security officer to make sure traffic on port 993 is being allowed out to the O365 IP ranges.  I'd suggest doing the same to rule that out.  If you do, please let us know if that worked for future generations to be able to solve the problem ;-)

Like Dawn Fama likes this

Allan, thanks for your reply. I'll test it soon, I'm currently on holiday.

0 votes
Jack Brickey Community Leader Aug 07, 2018

This is working fine for me so a bit perplexed as to why it is not for others. @Bill Kunneke and @Allan Libby did you open a support request w/ Atlassian Support?

Not yet, that is the next step.

I did open a ticket with Atlassian Support and it didn't get resolved.  The funny thing is, we carved out all this time to test Service Desk and never in my wildest dreams would I have thought that connecting to a mail service would take more than 5 minutes.  Hours of work over the last few months though has not gotten me a single step closer.  Someone on the team hacked a work around, it'll have to do but it baffles me why Office 365 email would be so problematic.

Jack Brickey Community Leader Aug 07, 2018

If memory serves it only took 5m for us. Define a new O365 email, enter it into the project emails configuration and attach to a request type. I will look at how the email is configured in O365 and comment back here. If possible could you post screenshots of your project config email screen?

Jack Brickey Community Leader Aug 07, 2018


here is what i have set up on my config and as I said it works fine. Bill, as you mentioned it needs to be a real email user and not shared which is what you have done. If these settings don't work I would definitely seek Atlassian's assistance.



Jack Brickey Community Leader Aug 07, 2018

it sure seems that if you guys have it set up as above it would be something on the Outlook side TBH.

FWIW, we tried these settings and tried them again.  Still not working.  Like I said, we've moved on but maybe this will help someone else.  Thanks for all the help.

Bill, did you check firewall settings?  I am doing that tonight (takes a while for our wheels to turn here) to double check.

I'm cutting my losses, we spent a LOT of time on this and I can't afford to lose any more.  I tried the config (again) that Jack provided even though I knew we had tried these settings before.  As for the firewall rules, it's a lot of work for me to engage someone in IT to check the firewall and it would be a mountain of paperwork to get it changed if that was the issue.  Given we have a hosted solution, I'm not even sure we can control this.  We've moved on, disappointed to say the least that we spent this much time on something that should just work right out of the box.  Again, thanks for the attempts.

If it was a firewall issue it's not Jira's fault, but your organization's policies (currently I am fighting mine too).  I'll update this thread after we get our firewall settings changed and I test it out again.

Like Dawn Fama likes this
0 votes

Hi Bill,

Those messages are a bit generic for me to give you a straightforward answer, but, it is likely an issue with the SSL certificate. Are you using a custom domain or Microsoft's Office 365 default url when trying to set up the mailbox?


The mail server is  

I am also having the same issue.  Jira only says 'Unfortunately JIRA couldn't connect to the mail server. Here is what the mail server said: "Connection timed out: connect"'

We finally gave up on it, couldn't get help here or on the web.  My suggestion was to stay on Zendesk but ultimately we hacked around the issue by creating a GMail account that auto forwards to the Microsoft account.  It's ugly, but it works.  Best of luck.

Darn.  Neither of those are an option for us :-(  I saw on another ticket on here that someone got it to work, so I know its possible.  Thanks for responding!

Suggest an answer

Log in or Sign up to answer

Atlassian Community Events