How to compare two commits in BitBucket?

I came across this question while looking for a way to compare a single file across two different commits. The instructions for doing so are slightly different than those above, so I wanted to share:

  1. Browse to the file in question in the "Source" view
  2. Drop down the file's view option and select "Diff":

'Diff' view option

  1. Once the file's diff has loaded, drop down the history options and select the commits that you want to compare between:

Select commits to compare


BitBucket Cloud (bitbucket.org) supports commit comparison on the branch compare page:

  1. Navigate to a repo
  2. Click the '+' menu in the left-nav
  3. Click 'Compare branches and tags'
  4. Paste your commit hashes into the search fields in the branch/tag dropdowns
  5. Click 'Compare'

This URL worked for me: https://bitbucket.org/<OWNER>/<PROJECT>/branches/compare/<commit1>..<commit2>#diff, short hashes can also be used.

Screenshot:

enter image description here

Tags:

Git

Bitbucket