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

What links a JIRA issue to Bitbucket commits/PRs


We are using the server versions of both JIRA and Bitbucket. When I view JIRA project releases I can view issues belonging to that release. The Development column shows commits and the merge status of pull requestsl linking to those tickets. 

I see commits linked from having the JIRA issue ID in the commit message. What else creates this link? Branches with a JIRA issue ID in the name? Anything else?


1 answer

1 accepted

6 votes
Answer accepted

JIRA issues are linked when you mention the JIRA key in Bitbucket, either in the branch name, as part of the description or comment in a pull request or as part of the commit comment (as you have seen). 

Here is some more information about the integration,

Perfect. Thank you!

Do user forks not apply?

I committed to a user repo under my account, which displayed the commit fine in the Development area in the JIRA issue.

When I attempted the same in a forked repo under my account, the commit did not display in the JIRA issue.

I also tested with a fork that is under a project, not a user account, and that displays fine.


I've run into this just now, I find that issues are linked in the Bitbucket PR if I mention the JIRA ticket in the git branch name or in the git commit message, but they if I mention them in the PR description or in a comment then the text is hyperlinked but the ticket number does not appear at the top as a linked ticket. This doesn't seem to be the expected behaviour, going by the answer above?

Like # people like this

Automatic linking with a JIRA ticket by mentioning the key in a commit doesn't work for me either (though it used to work in the hosted Bitbucket). Has anything changed since then?

Like # people like this

It doesn't work for me either, but it may because I am using the free versions, I do not know for certain.

Auto linking of the commit message to the jira works, but the commit message is not showing up in the jira task. Breeze does this much better

Come on atlassian, lift your game

What about when you have already done several commits in a new branch. And THEN decide to create a Jira issue?

it is not easy to modify all my existing commits to have the Jira issue ID. 

@ChuckieAJ try adding the ticket number in the PR title. Or, if need be, it always works to manually add a weblink to the Jira ticket, containing the URL of the PR.

I have been able to associate a Jira ticket with bitbucket branches, commits and PRs by using the suggested method.

What I don't understand is when my branch already has the issue key at the head of the name and is linked to Jira, when creating a PR I also need to remember to mention it in the PR description?

This seems counter intuitive as the main purpose of automation is to help mitigate errors made by people. If I create the branch from the Jira issue then after that, all commits and PRs should be linked to the issue.

Am I missing something? Does it not look at the branch to see if it is linked to an issue?

Do we expect every developer to remember to add that key every commit and every PR?

Suggest an answer

Log in or Sign up to answer

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you