Bitbucket Webhook Jenkins integration connects your Bitbucket repositories to Jenkins so that every code push automatically triggers a build, removing the need for manual intervention in your CI/CD pipeline.
- Install the Bitbucket Plugin in Jenkins from Manage Plugins.
- Create a repository in Bitbucket and link it to a new Jenkins Freestyle Project under Source Code Management.
- Enable the “Build when a change is pushed to BitBucket” trigger in Jenkins.
Add a webhook in Bitbucket Repository Settings, pointing to your Jenkins server URL.
This approach ensures seamless code deployment across environments while maintaining version control capabilities, automated testing protocols, and continuous integration practices for optimized software development lifecycles.
Every time a developer pushes code, two things should happen automatically: Bitbucket records the change, and Jenkins kicks off a build. Without a proper webhook integration between the two, that handoff breaks, and teams end up babysitting builds instead of shipping features.
According to the JetBrains State of CI/CD 2026 report, Jenkins holds a 28% adoption rate across organizations of all sizes, making it the second most used CI/CD tool globally. Pair that with Bitbucket, one of the most widely used Git repository platforms in enterprise teams, and you have a CI/CD combination that a significant chunk of the industry runs on.
Getting the two to talk to each other is not complicated, but it does require the right sequence. Setting up Bitbucket webhooks to trigger Jenkins builds means every push, pull request, or branch creation is immediately acted on, with no manual intervention, no delayed pipelines.
This guide covers how to wire that up from scratch, and how to extend it to multibranch pipelines when your team scales.
Table of Contents
Prerequisites for Setting up BitBucket Webhook Jenkins Integration Workflow
Before you begin the integration setup, make sure you have the following in place:
| Requirement | Details |
| Jenkins Instance | A running Jenkins server (version 2.x or later) accessible via a public URL or network-reachable endpoint. If running locally, use a tunneling tool like ngrok to expose Jenkins to Bitbucket. |
| Bitbucket Account | An active Bitbucket Cloud or Bitbucket Server account with admin-level access to at least one repository. |
| Java (JDK) | Jenkins requires Java 11 or Java 17. Confirm installation by running the java version in your terminal. |
| Git | Git must be installed on the Jenkins server. Jenkins uses Git to clone repositories from Bitbucket during builds. |
| Admin Access to Jenkins | You need admin privileges on Jenkins to install plugins, create jobs, and configure build triggers. |
| Network Connectivity | Bitbucket must be able to reach your Jenkins URL over HTTP/HTTPS to deliver webhook payloads. Ensure firewalls and security groups allow inbound traffic on the Jenkins port. |
Steps to Set up Bitbucket Webhook Jenkins Integration
To automate the testing and deployment of your code, you need to set up a Bitbucket Jenkins webhook that triggers a build whenever you push changes to your repository. You may also use generic Jenkins webhooks to automatically trigger Jenkins builds when you post code changes to your Bitbucket repositories.
Now that you have an idea about what Bitbucket and Jenkins are capable of, you are ready to learn about the steps involved in building the BitBucket Webhook to Jenkins Integration. The BitBucket Webhook Jenkins Integration is a four-stage process including the following steps:
Step 1: Install the Bitbucket Plugin in Jenkins
Step 2: Create a New Repository using Bitbucket
Step 3: Create a New Job in Jenkins
Step 4: Push code to Jenkins using Bitbucket webhooks
Read more to learn how to set up Bitbucket pipelines.
Step 1: Install the Bitbucket Plugin in Jenkins
The first step involved in setting up BitBucket Webhook Jenkins Integration requires you to install the BitBucket Plugin in Jenkins. Follow the steps given below to install the plugin:
- Log in to your Jenkins account and open the Dashboard section.
- Click on Manage Jenkins from the list of available options.
- Now, click on Manage Plugins and navigate to the Search bar. Enter Bitbucket Plugin in the search bar and install it.
Step 2: Create a New Repository using BitBucket
Once you have installed the BitBucket Jenkins webhook, you will need a repository in BitBucket to link it with Jenkins. The second step in building BitBucket Webhook Jenkins Integration involves creating a new BitBucket repository. Follow the steps given below to do so:
- Log in to your BitBucket account using the appropriate credentials.
- Once you have successfully logged in to your BitBucket account, click on the Create Repository button.
- Add a name for your Project and Repository. You can also select the access level for your repository and make it private or public according to your needs. Once you are done filling all the required fields, click on Create Repository to save and create the repository.
Step 3: Create a New Job in Jenkins
- Once you have the repository ready, go back to your Jenkins account and open the Dashboard.
- Select the option New Item from the list of options available to create a new Jenkins Job.
- Give a name to the Job that you are creating and select the option Freestyle Project. Once you are done filling the required fields, click on the Ok button to create a new Jenkins Job.
- Now navigate to the Source Code Management section and click on the Git radio button.
- Add the link to your BitBucket repository that you created in the previous step to set up the Jenkins BitBucket Webhook Integration.
- Navigate to the Build Triggers section and mark the option “Build when a change is pushed to BitBucket“. Then click on the Save button to save all the changes.
Step 4: Push Code to Jenkins using Bitbucket Webhooks
The final step of the BitBucket Webhook Jenkins Integration is to configure it to push code-based changes to the Jenkins Server whenever new code is committed to the BitBucket Repository.
- Open BitBucket and navigate to the Repository Settings page.
- Select the option Webhook and click on the Add Webhook button.
- Give a name to the BitBucket Webhook and add the Jenkins URL in the URL field. You can also skip the certificate verification.
- Once you have filled the required fields, click on Save to save all changes.
Once you follow the above instructions in the correct sequence, you will be able to set up BitBucket Webhook Jenkins Integration in no time!
How to Trigger Multibranch Jobs from Bitbucket Server?
The Bitbucket Branch Source plugin allows you to integrate Bitbucket with multibranch projects like Pipeline Multibranch. The API listens for notifications at the endpoint /bitbucket-scmsource-hook/notify.
- Configuration in Jenkins
- Configuration in Bitbucket Server
If you also work with other repository platforms, you can explore a similar setup for Gitlab Webhook Jenkins integration or Jenkins GitHub webhook configurations.
Configuration in Jenkins
Global Configuration (Bitbucket Branch Source 2.2.0 and later)
Navigate to Manage Jenkins → Configure System → Bitbucket Endpoints and add your Bitbucket server endpoint. This step is required for Jenkins to recognize and communicate with your Bitbucket Server instance.
Note: This configuration step does not apply to versions earlier than Bitbucket Branch Source 2.2.0.
Setting Up a Multibranch Pipeline
To track a single repository across all its branches:
- Create a new Multibranch Pipeline item in Jenkins.
- Under Branch Sources, select Bitbucket as the SCM source.
- Configure the SCM source settings. Hover over the help tooltips next to each Behavior option for guidance on what each one controls.
For older versions (prior to 2.2.0): There is no global system configuration needed. Configure the SCM directly per the Bitbucket Branch Source Plugin instructions. In the Advanced section, provide the Bitbucket server URL and the SSH port if SSH authentication is used for checkout.
Setting Up a Bitbucket Team/Project Source
To monitor multiple repositories within a single Bitbucket project:
- Create an item of type Bitbucket Team/Project in Jenkins.
- Select Bitbucket Team/Project repository source under Branch Sources.
- Configure the SCM source settings as needed.
For older versions: Provide the Bitbucket server URL and SSH port under the Advanced section, following the Bitbucket Branch Source Plugin instructions.
Hook Management (Auto-Register Webhooks)
Once a project is saved, Jenkins automatically listens for events on /bitbucket-scmsource-hook/notify. To allow Jenkins to automatically register webhooks without manual setup, enable the Manage Hooks option under Manage Jenkins → Configure System → Bitbucket Endpoints.
There are two webhook management implementations:
- Native: Automatically creates the webhook under the Webhooks section using Bitbucket’s native webhook support.
- Plugin: Automatically creates the webhook under the Post Webhooks section, using the Bitbucket WebPost Hooks Plugin.
Both can be used simultaneously, but the Native option is recommended if you are using Bitbucket Server 5.4.0 or later, which includes built-in webhook support.
For older versions (between Bitbucket Branch Source 2.1.1 and 2.2.0): Use the Auto-register webhook option (available since Post Webhooks for Bitbucket 1.4.1) to let Jenkins register webhooks automatically.
Configuration in Bitbucket Server
If Jenkins is not configured to auto-manage webhooks, you can manually create them in Bitbucket. There are two approaches depending on your Bitbucket Server version.
Bitbucket Branch Source 2.3.0+ with Bitbucket Server 5.4+
Bitbucket Server 5.4 introduced a native Webhook API, which Bitbucket Branch Source 2.3.0 supports.
To create a webhook manually:
- Go to your repository in Bitbucket Server.
- Navigate to Settings → Webhooks and click Create webhook.
- Enter any title and set the URL to: $JENKINS_URL/bitbucket-scmsource-hook/notify?server_url=<BITBUCKET_URL>
- Use the Test Connection function to verify Jenkins can receive the webhook.
Note: If you are using the Bitbucket WebPost Hooks Plugin, the URL should simply be $JENKINS_URL/bitbucket-scmsource-hook/notify, as the plugin automatically injects server_url.
- Select the Repository and Pull Request events Jenkins should respond to. The screenshot above shows the events automatically handled by Bitbucket Branch Source as of version 2.4.0.
- Save and confirm the webhook is marked as Active.
Important: If the manual webhook does not work, enable the Bitbucket Branch Source plugin to auto-create webhooks. This will also help confirm the correct URL format.
Any Version: Using the Post Webhooks for Bitbucket Add-on
The Post Webhooks for Bitbucket add-on works with all versions of Bitbucket Branch Source and Bitbucket Server. It was created by the community to support the Bitbucket Branch Source plugin as a part of JENKINS-33507, and its source code is available on GitHub.
Once installed, the add-on adds a Post Webhooks section to your repository’s Settings.
- Click Add WebHook in the top right.
- Enter any title and set the URL to: $JENKINS_URL/bitbucket-scmsource-hook/notify
- Select the repository and pull request events Jenkins should handle.
Note: In older versions of this add-on, event types could not be customized. They were preset to cover most pull request changes and repository pushes.
- Save and confirm the webhook is not marked as inactive.
Introduction to Jenkins
G2 rating: 4/5(562)
Jenkins is an open-source automation tool written in Java that includes plugins for Continuous Integration. It enables you to automate the execution of a series of actions to achieve the Continuous Integration process. Jenkins is used to build and test your software projects continuously, making it easier for developers to incorporate changes to the project and for users to leverage a fresh build. It also enables you to deliver software on a continuous basis by integrating with a wide range of testing and deployment technologies.
Organizations can use Jenkins to automate and speed up the software development process. Jenkins manages and controls software delivery processes throughout the entire Development Lifecycle, including Build, Documentation, Testing, Packaging, Staging, Deployment, Static Code Analysis, and much more.
If you are evaluating how Jenkins compares to workflow orchestration tools, this guide on Airflow vs Jenkins covers the key differences.
Key Features of Jenkins
- Easy installation and configuration: Jenkins is a self-contained Java program that is platform-independent. It is available as both a standard installer and a .war file, and its minimal web interface makes post-installation configuration straightforward.
- Open-source foundation: Jenkins is completely free to use and is backed by a strong open-source community, which continuously contributes to its growth and reliability as a Continuous Integration tool.
- Distributed builds: Jenkins is architected to efficiently distribute workloads across multiple machines and platforms, enabling faster build, test, and deployment cycles.
- Rich plugin ecosystem: Supported by an active community, Jenkins offers close to 1,500+ plugins in its Update Center, extending its capabilities across a wide range of tools and workflows.
Pros of Jenkins
- No licensing costs: Jenkins is entirely free, making it accessible for teams of any size without budget constraints.
- Extensive integrations: With 1,900+ plugins, it connects seamlessly with tools like Git, Docker, Kubernetes, and Slack.
- Community support: A large and active community ensures abundant documentation, tutorials, and forum assistance.
- Pipeline flexibility: Supports both declarative and scripted pipeline styles to suit different team preferences.
- Full environment control: Being self-hosted means no vendor lock-in and complete ownership of your build infrastructure.
- Scalable build distribution: Jobs can be spread across multiple agents, significantly reducing build times at scale.
Cons of Jenkins
- Ongoing maintenance burden: Teams are fully responsible for upgrades, patches, and infrastructure management.
- Steep learning curve: Configuring complex pipelines demands considerable time and technical expertise.
- Outdated interface: The UI lacks the modern polish seen in newer CI/CD platforms.
- Plugin compatibility risks: Updates can occasionally break compatibility between interdependent plugins.
- Resource demands: Running Jenkins at scale requires careful capacity planning and infrastructure investment.
What Users Say About Jenkins
“What do you like best about Jenkins?
Jenkins is a powerful CI/CD tool for organizations that want to automate work such as building, deploying, administering, testing, and more. You can create separate jobs for each stage—like build, deploy, and test—and then organize them together in a group for better structure. It’s also straightforward to install and configure. On top of that, there are many plugins available that make it easy to integrate Jenkins with other tools.”
Introduction to BitBucket
G2 rating: 4.4/5(1,007)
Bitbucket is a Git Repository Management System designed specifically for professional teams. It acts as a central hub that is used to manage all Git Repositories, Collaborate on Source Code, and guide everyone through the Software Development Cycle. It is a part of the Atlassian family, with tools like Confluence, Jira, and others to help technical teams reach their full potential. Teams that use both tools together can streamline project tracking through a Jira Bitbucket integration. BitBucket can be deployed in three different ways, which are BitBucket Cloud, BitBucket Data Center, and BitBucket Server.
BitBucket provides teams with a secure and scalable environment to store, review, and manage code changes throughout the entire software development lifecycle. It supports branching strategies, pull request workflows, and inline code reviews, enabling teams to maintain high code quality while keeping development cycles efficient. Whether you are a small startup or a large enterprise, Bitbucket adapts to your team’s needs by offering flexible access controls, deployment options, and seamless integrations with the tools your team already relies on.
Key Features of BitBucket
Some of the key features of Bitbucket are as follows:
- Public repositories & collaboration: BitBucket allows developers to upload their code to repositories and make it public, enabling others to view developer profiles and collaborate on projects in real-time.
- Third-party integrations: BitBucket integrates with a variety of third-party tools and apps, allowing users to sync data and optimize workflows. It also connects with code editors, so repositories can be managed directly from the editor.
- User-friendly interface: BitBucket has a user-friendly interface, making it easy to use and understand. It also maintains a detailed history of all modifications made within a project.
- CI/CD pipeline support: BitBucket supports pipeline trigger configurations for automated CI/CD workflows directly within the platform.
Pros of BitBucket
- Atlassian ecosystem: Offers native, out-of-the-box integration with popular Atlassian tools like Jira, Confluence, and Trello, making it a natural choice for teams already in that ecosystem.
- Built-in CI/CD: Bitbucket pipelines eliminates the need for a separate CI tool by allowing builds and deployments to run directly within the platform.
- Granular access control: Provides fine-grained branch permissions and merge checks, giving enterprise teams precise control over who can modify what.
- Robust pull request workflows: Features inline commenting, reviewer assignments, and approval mechanisms built directly into the pull request interface.
- Flexible deployment options: Available as Cloud, Data Center, or Server, accommodating a wide range of infrastructure requirements and preferences.
- Free tier for small teams: Supports up to 5 users with unlimited private repositories at no cost, making it an attractive option for startups and small teams.
Cons of BitBucket
- Smaller community: Compared to GitHub, BitBucket has a more limited pool of third-party content, extensions, and community-driven resources.
- Performance issues: Some users experience sluggish page loads and slower response times, particularly when working with larger repositories.
- Bitbucket server end-of-life: Atlassian officially ended support for BitBucket Server in February 2024, requiring affected teams to plan and execute migrations.
- Restricted free CI minutes: The free tier of Bitbucket pipelines caps build time at just 50 minutes per month, which can be limiting even for small projects.
- Weak code search: The built-in code search functionality falls short when compared to the more powerful search capabilities offered by GitHub or GitLab.
What Users Say About Bitbucket
“What do you like best about Bitbucket?
I enjoy using Bitbucket because it’s an easy way to commit and push code. I like the MCP servers that allow us to connect to AI apps like Codex or Claude Code and pull all information seamlessly. I appreciate the ability to merge the code via CI/CD pipelines, which makes integration smoother. The connection created by the app to the server through Cloud or Puppet simplifies the process, so I don’t have to manually copy and paste the code. Additionally, the initial setup of Bitbucket was very easy compared to Perforce, which has been beneficial for our team.”
Hevo Data is a fully managed, no-code ELT platform that makes data movement simple, reliable, and transparent. It helps teams connect over 150 sources to leading data warehouses in minutes, without requiring engineering effort or ongoing maintenance.
Here is what makes Hevo a strong fit for data teams:
- Simple to Use: Get started in minutes with a guided, no-code setup that requires no scripting or infrastructure management. Build, monitor, and scale data pipelines through a visual interface designed for speed and ease.
- Reliable: Built for resilience, Hevo features auto-healing pipelines, intelligent retries, and a fault-tolerant architecture that keeps data flowing even when sources fail. Automatic schema handling adjusts to API or structure changes without breaking workflows.
- Transparent: Track every pipeline in real time through unified dashboards, detailed logs, and data lineage views. Batch-level checks help detect anomalies early, keeping your data accurate and consistent.
- Predictable Pricing: Hevo’s event-based pricing model provides complete cost transparency. There are no hidden fees, usage credits, or surprise overages.
- Scalable: Hevo automatically scales to handle growing data volumes and high-throughput workloads without downtime or manual tuning.
Build a Reliable Workflow with Bitbucket Webhook Jenkins Integration
Jenkins allows developers to trigger actions or events, and BitBucket allows them to keep track of version control. BitBucket Webhook Jenkins Integration can optimize the Software Development process to a great extent. This article introduced you to the steps required to set up BitBucket Webhook Jenkins Integration in a seamless manner.
You can also explore how to set up a Jenkins Jira integration to further connect your development and project tracking workflows. If you want to integrate data from various data sources into your desired Database/destination for free and seamlessly visualize it in a BI tool of your choice, Hevo Data is the right choice for you! It will help simplify the ETL and management process of both the data sources and destinations.
Want to take Hevo for a spin? Sign up for a 14-day free trial and experience the feature-rich Hevo suite first hand. You can also have a look at our unbeatable Hevo Pricing that will help you choose the right plan for your business needs!
Share your experience of learning about BitBucket Webhook Jenkins Integration! Let us know in the comments section below!
Conclusion
Jenkins allows developers to trigger actions or events, and BitBucket allows them to keep track of version control. BitBucket Webhook Jenkins Integration can optimize the Software Development process to a great extent. This article introduced you to the steps required to set up BitBucket Webhook Jenkins Integration in a seamless manner. If you want to integrate data from various data sources into your desired Database/destination for free and seamlessly visualize it in a BI tool of your choice, Hevo Data is the right choice for you! It will help simplify the ETL and management process of both the data sources and destinations.
Want to take Hevo for a spin? Sign Up for a 14-day free trial and experience the feature-rich Hevo suite first hand. You can also have a look at our unbeatable Hevo Pricing that will help you choose the right plan for your business needs!
Share your experience of learning about BitBucket Webhook Jenkins Integration! Let us know in the comments section below!
FAQ on BitBucket Webhook Jenkins Integration
How to connect Bitbucket webhook with Jenkins?
– Open Bitbucket and go to the repository where you want to set up the webhook.
– Click on the repository’s settings (usually a gear icon in the left sidebar).
– Create a Webhook
– Configure the Webhook
Can we integrate Bitbucket with Jenkins?
Yes, You can integrate Bitbucket with Jenkins
How do I trigger a Bitbucket pipeline webhook?
– Set Up the Webhook in Bitbucket
– Ensure your bitbucket-pipelines.yml file is set up correctly to handle the webhook triggers.