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

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

How to backup the Bitbucket on cloud?

How to backup the Bitbucket on cloud?
Does Atlassian have a backup? Is it restorable? 

8 answers

1 accepted

Bitbucket Cloud is backed up regularly by Atlassian. Atlassian has the ability to restore from its backups but otherwise you should not have to worry.

If you are still concerned, Git is a Distributed Version Control System, you could always just sync your repository to other locations to back it up.

You can read about this more here:

I hope that helps.

Update for 2020:

When I originally wrote this comment in 2016 I thought that people were mostly concerned about Bitbucket as a platform losing their data. However, that does not seem to be the concern in all of the recent comments so I feel like an update is required.

It seems that the most common concern these days is from mistakes that people might make on their own repositories and people desire the ability to fix these themselves by restoring from a Backup. I don't work directly on the Bitbucket Cloud team but I can direct you to the three issues in the public backlog that may track towards this.

Please vote on the issue that best reflects what you would want to see implemented and please comment on the issue with why you would want to see it implemented so that Bitbucket Cloud PM can triage the requests. Cheers!

Your answer in is conflict with the provided link:

"Our backups are for disaster recovery purposes only. We are not able to use our backups to restore repositories that have been deleted by an end-user."

To me this means that end users do not have access to backups.

Like # people like this
Deleted user Jun 11, 2019

Any update on this? We want to ensure, no repository is lost, when some dude accidentally deletes a repository.

Like # people like this

I'd suggest taking action instead of waiting for Atlassian to come up with a reasonable plan. Because obviously they won't do that soon. Please check my answer to the question. I believe you can benefit from it.

Deleted user Jun 11, 2019

Thanks Cem, but it's not only about the source code, it's also about all the settings made within the repository.

Like Haas likes this

FWIW: I think it's positively scandalous that Atlassian doesn't provide a straight-forward way of grabbing backups of your team's repos.

It's a complete cop-out to say "you can always sync your repos" -- Yeah, I can.   Shall I go from office to office, then, and find the most recent person who's synch'ed every single one of our repos?  "Hey team... I've got the XYZ repo sync'ed form 10 November 2019... anybody got anything newer?  How about the ABC repro, and the DEF repro, and the..."

Silly.  They just should give us a way to dump all our stuff.

Like Andreas likes this

I originally made this comment in 2016 and, even though I thought that it met the need, I can see from the more recent comments that it is not quite what people want.

I've created some links to existing issues in the Bitbucket Cloud public backlog so that we can bring the comments from this thread into issues that the PM's will more directly triage.

If none of those issues match what you want, please report a new issue for the Bitbucket Cloud team to triage. Otherwise, please vote on an existing one and comment with why you want that feature. I hope this helps. Cheers!

Absolutely ridiculous - we just became premium members and cannot believe the LACK of backup/restore for a premium cloud service... both non-existent and for some minimal functions, non intuitive.  Anyone from Atlassian here that can provide some insight on what they are doing in this area?   

Then I should clarify: we have been running it on an AWS Linux machine for a few months and recently switched to Ubuntu 18.04. It has been running successfully so far. Besides regular checks, I also tested the recovery process, which went well.

Great! Thanks for the feedback @Haas

I think I'll deploy to Kubernetes.

Like Haas likes this

I suggest taking a look at SCM Backup tool:

We've been using this tool through a Jenkins job to take daily backups of our git repositories. It's very convenient and works cross-platform. 

Sounds like a good idea except for these inspirational words: "So far, SCM Backup has been written and tested on Windows only. Technically, it should run on Linux and MacOS as well, but this has not been tested yet."

The scm-backup solution works well.

Thanks Hass!

Like Haas likes this

If you JUST want some simple way to backup your stuff, see this issue.


For anyone looking for a quick solution, here's a Docker file which will back up your Bitbucket repos easily. 


# Dockerfile for SCM Backup
# With thanks to Christian Specht for creating SCM Backups.
# 1. Install Docker
# 2. Copy the contents of this file to a file called 'Dockerfile'
# 3. Create settings.yaml -- see
# 4. Build Docker Image:
# docker build -t scm-backup .
# 5. Run the backup with output to ./bitbucket-backups:
# docker run -t --mount src=`pwd`/bitbucket-backups,target=/scm-backup-out,type=bind scm-backup

FROM ubuntu:18.04

WORKDIR /scm-backup

# Install .NET core and SCM Backup
RUN apt-get update && apt-get -y install software-properties-common && \
add-apt-repository universe && apt-get update && \
apt-get -y install sudo wget unzip apt-transport-https git && \
wget -q && \
dpkg -i packages-microsoft-prod.deb && rm packages-microsoft-prod.deb && \
apt-get update && \
apt-get -y install dotnet-sdk-2.2 && \
wget && \

# Copy settings.yml from local filesystem to the container (rebuild every time settings.yml is updated)
COPY settings.yml .

# Run the backup
ENTRYPOINT dotnet ScmBackup.dll

Thanks @Rori Stumpf. This looks great! I'm sure there will be a lot of people who can benefit from this. If Christian agrees, I'd like to take this to the github repo of the project, so it can reach to more people. Is that OK with you? 

@Haas Thanks for the offer but I am actually working on cleaning it up and will create a pull request for the Github repo. Should be done in a few days. 

@Rori Stumpf hows the progress on that? :)

Like # people like this
Like Bradley MacDonald likes this

Like Massaioli, I'll assume you're running Git, but the same advice applies to folks running Mercurial:

Robert Massaioli [1]
> Git is a Distributed Version Control System, [so] you could always just sync your repository to other locations to back it up.

Better yet, remember that

1. Your Cloud repo is just a remote of your local repo, which is just part of your local work directory, which is (wait for it ...) on your local file system! which you should be backing up regularly! if you value your sanity.

2. Your local repo is only part of your local work dir. Your local work dir(s) should contain all code (wait for it ...) on which you are working. Your repos (local or remote) are not backups for your local work! They should only contain work that has been finished (e.g., tested). So you still need to backup your local work dir--i.e., your local filesystem--even if you have a remote repo.

that doesn´t cover how and what reasons atlassian is used for. There are whole bunch of functionalities to link between source code and product/project management (jira) and some need to guarantee that correct connection between change issues/features/bugs and corresponding changes in the source code for eg. regulatory reasons.

Therefore a FULL backup is needed which means quite a lot more than "only" the sources but furthermore a whole history, users, links, etc,.....

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bitbucket

New improvements to user management in Bitbucket Cloud 👥

Hey Community! We’re willing to wager that quite a few of you not only use Bitbucket, but administer it too. Our team is excited to share that we’ll be releasing improvements throughout this month of...

3,850 views 10 16
Read article

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