Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.

Jira_Rest 401 Error Code


Hello, I hope you can help,

When attempting to push or view a defect (by hovering over it) I am met with the error message:

Plugin "Jira_REST" returned an error: Invalid user or password or insufficient permissions for the integration user (HTTP code 401). Please make sure to use your actual JIRA username for the integration (not your email address, for example).

I have seen a lot of topics on this, but nothing that has worked yet, so I’m going to start off by letting you know what I have checked.

The settings work with the generic username and password i created for a fallback, but it is rejecting my own credentials. So the rest of the config works

I am using the username, not an email address. I have checked that the username is correct repeatedly.

I am an admin on the Jira and have access to the project.

I am sure the password is correct. If I paste from clipboard it lets me log in to Jira. if I paste it in my user settings (on testrail) I fail to connect. If I paste it into the plain-text defects integration setup, I fail to connect. If I do the same with the fallback information, it works.

I’d prefer everyone to use their own credentials, but until I find out why my own don’t work, I don’t feel comfortable trying to achieve this.

Any help would be much appreciated.


Hi Jonathan,

Thank you for the post and detailed information on what you have tried so far. As of late we have seen that JIRA has been updating the way users log into JIRA. From what we have seen using the actual email address of the integration user appears to resolve this. You can simply go to Administration > integration and scroll down to the bottom of the page and edit the username. From here enter the entire email address and save your changes. Once you have done this see if the error still displays.


As suggested, I have tried substituting the email address for the username. Unfortunately, this did not resolve the problem.

Additional information: We’re using the Jira Cloud solution, if that’s helpful at all.

Anything else I can try?


Hey Jonathan,

Thank you for the follow up. It appears that with the Atlassian account switch, your JIRA username and/or email address will work but the password should be the Atlassian account password which can differ from your JIRA password.

Can you please ensure that you are using the Atlassian account password for the integration user and see if this works?


Thank you very much for your assistance. It is now working. In case this is of any help for you or anyone else, here is what I ended up doing:

I went to to see if my password was the same as my Jira, it was. Logically, this should have meant that the credentials I used before were correct. But just for kicks, I changed the password to the exact same thing it already was, confirmed by entering the same password in the ‘old’ and ‘new’ password boxes.

…My credentials are now working to retrieve data through testrail. I can think of no logical reason for this other than a hiccup on Jira’s end with regards to their user account transition.

Again, thank you for your assistance.


i followed the previous instructions but am still having issues (we just upgraded/converted to Jira Cloud). It looks like TestRail is changing my passwords on the config screen. Has anyone seen this? Thanks.


Hi Mary,

Thanks for your reply! TestRail wouldn’t automatically change any passwords when adding these on the config screen. Perhaps this could also be some password management tool/extension that would be changing this automatically when it detects a username/password field? I would recommend disabling any extensions in case this is what’s causing the issue. Hope this helps!



I’ve seen the “Remember Passwords” functionality of browsers/plugins change the value in the password field when adding a user. (It does this on many pages, not just TestRail.) For TestRail I find it easier to use the Add Multiple Users button because there is no password field on the subsequent form.


We recently switched to Jira Cloud and now have a single sign-on to Atlassian products with dual authentication. For the dual auth, basically after logging in, a code is sent to our phone as well. I’m also seeing the 401 error when hovering over a Jira item in TestRail. Do you have any suggestions on how to get the preview to show when hovering?

Thank you for your help.