KBAISE/ for lovable
Library
Docs

Sync your Lovable project with Bitbucket

about 5 minBuildingchecked 9d agoOfficial page
The short version

You can connect your Lovable project to Bitbucket Cloud to automatically back up your code and sync updates both ways. Changes you prompt in Lovable push to Bitbucket, and changes pushed to Bitbucket sync back into your Lovable project.

Anyone who wants an external code backup or plans to share code with developers using Bitbucket Cloud.

Do this, in order

  1. 1

    Go to Project settings, open the Git tab, select Bitbucket, and click Add connection.

    This begins connecting your Lovable workspace to your Atlassian account.

  2. 2

    Click Authorize with Bitbucket and log into an Atlassian account that has administrator rights to your workspace.

    Lovable needs administrator access to set up automated change notifications between Bitbucket and Lovable.

  3. 3

    Select your Bitbucket workspace from the list and click Connect.

    This links your chosen Bitbucket workspace to Lovable.

  4. 4

    In your project's Bitbucket settings, click Connect next to the workspace.

    Lovable automatically creates a private repository named after your project and turns on live sync.

Paste this into your project

Create a clear README.md file in the project root explaining what this application does, its key features, and instructions on how to install and run it locally once synced to an external repository.

Words decoded

Repository
A secure online folder on Bitbucket that stores all your project files and their revision history.
Branch
A separate workspace line for your code, letting you work on features without affecting the main app.
Webhook
An automated alert Bitbucket sends to Lovable whenever someone updates the code.
Two-way sync
An automatic link where edits made in Lovable push to Bitbucket, and changes made in Bitbucket flow right back into Lovable.

Where people get stuck

  • Lovable only supports Bitbucket Cloud (bitbucket.org), not self-hosted Bitbucket Server or Data Center.
  • You cannot import existing Bitbucket code into Lovable; Lovable only exports out to create a fresh repository.
  • Brand new Bitbucket workspaces take a few minutes to activate before they can accept code pushes.
  • Lovable only tracks and syncs one branch at a time; code sent to other branches will not show up in Lovable until you switch branches or merge.
  • Deleting or moving the repository on Bitbucket breaks the sync connection.

The short version, steps, decoder and prompt on this page are written automatically from Lovable's own documentation and can lag or misread it. The official page is always the authority.