Skip to content
Docs

GitLab

Connect gitlab.com or your own GitLab server, then link merge requests and issues to tasks, see their live status and merge from the task.

BetaOwnerExecutiveTeam leadIndividual contributorLast updated 15 November 2026

This feature is in beta. If you do not see it, ask your admin to turn it on for your organization.

SetupAn admin turns on GitLab for your organizationWhoOwners and executives connect the server and map projects. People with the merge permission can merge. Everyone sees links on tasks they can already see.Roles

The GitLab integration connects your organization to one GitLab server. That can be gitlab.com or a server you run yourself. Once projects are mapped, a task can show its GitLab merge requests and issues with their live status, and a person can merge a merge request from the task.

It works like GitHub. An organization can use either or both.

  • An admin turns the integration on for your organization. Until then every screen below is missing.
  • You need a GitLab group or project access token with the api scope.
  • GitLab version 15 or later.
  1. Go to Organization settings > Integrations > GitLab.
  2. Enter the GitLab address: https://gitlab.com, or your own server’s address. Only https works.
  3. Paste the Access token. In GitLab, create it under the group or project’s Settings > Access tokens with the api scope.
  4. If your server uses a certificate signed by your own authority, paste it under CA certificate (optional), or upload the file. There is no option to skip certificate checks. An untrusted certificate is always refused.
  5. Choose Test and connect. Nothing is saved until the test passes. The page then shows the server, its version and who the token belongs to.

An organization connects to one GitLab server at a time. Replace the connection switches to another. Disconnect deletes the token ProjectBrain holds. Revoke it in GitLab too if nothing else uses it.

ProjectBrain learns about changes through a webhook. On the connection screen, copy the webhook URL and make a secret token. In GitLab, open the group or project, then Settings > Webhooks > Add new webhook, paste both, and tick:

  • Push events and Tag push events
  • Merge request events
  • Pipeline events
  • Deployment events
  • Issues events, and Comments
  • Confidential issues events and Confidential comments

Leave Enable SSL verification on. The secret is shown only once. Rotate secret token makes a new one, and the old one stops working at once, so paste the new one into GitLab straight away. A delivery with a wrong or missing secret is refused.

Map GitLab projects to ProjectBrain projects

Section titled “Map GitLab projects to ProjectBrain projects”
  1. On the connection screen, choose Sync projects to read the GitLab projects the token can see.
  2. Open a ProjectBrain project’s Code screen. Under GitLab projects, choose Add GitLab project and pick one.

A GitLab project can be mapped to one ProjectBrain project. Links update only for mapped projects. The project header shows a GitLab chip, which links to the Code screen for people who can manage it.

  1. Open the task and find its Development panel.
  2. Paste the merge request or issue address and link it.

An agent or an AI assistant can also link one for you. A merge request or issue whose GitLab project is not mapped is refused. A project path is not case-sensitive. A task whose key appears in a merge request title or branch name can be linked automatically when development tracking is on.

GitLab numbers merge requests and issues separately, so ProjectBrain shows group/project!7 for a merge request and group/project#7 for an issue.

Each link shows its live state: whether it can merge, how many approvals it has, and its pipeline checks. If ProjectBrain has not read a link yet, it says so. It does not say Not connected to GitLab unless the link truly cannot be read, for example the project is not mapped or the integration is off. Checking with GitLab… means GitLab is still working out whether it can merge, and the task updates by itself.

Merging uses your own GitLab account, never the organization’s token, so GitLab’s own log names you.

  1. Go to your profile settings and find the GitLab card. It appears only when the organization has GitLab connected.
  2. In GitLab, open your avatar, then Edit profile > Access tokens, and make a personal token with the api scope.
  3. Paste it and choose Link GitLab account. ProjectBrain tests it before saving, and shows who you are on that server.
  4. Unlink removes it. Revoke the token in GitLab as well.

A group or project token is refused here, because GitLab would show a bot as the person who merged. A token from a different GitLab than the connected one is refused too. If your organization changes servers, link again.

When a merge request can merge, its link on the task shows a Merge merge request button. It needs code.merge and your linked account. Without the account, the task says Link your GitLab account on your profile to merge from here.

ProjectBrain asks GitLab again at the moment you merge, because a check can change after the page loaded. If GitLab refuses, you see GitLab’s own reason. When the button is disabled, the task names what blocks it, such as a draft, a conflict, a missing approval or a pipeline that has not passed. Every attempt is recorded.

Linking an issue turns on syncing for it. Changes cross like this:

  • Closing, reopening, renaming or labelling an issue on GitLab adds a note to the task. The task’s status does not change unless you set a rule.
  • A label is noted, not applied.
  • A task closed or reopened in ProjectBrain closes or reopens its linked issue, and its assignee is sent.
  • Only comments marked “Share externally” go to GitLab. Internal comments never leave ProjectBrain. Comments from GitLab arrive as internal comments. Comments are added only, never edited or deleted on the other side.

A comment that reaches a public project cannot be withdrawn, and GitLab emails the people watching it. Share only what is fit for the public.

On a project’s Code screen, Let GitLab move a task: has two rules per GitLab project. Each starts as Do not change the status.

  • When its issue is closed
  • When its merge request is merged

A rule never moves a task out of done or canceled. The timeline note names the rule, not the person on GitLab.

Pause syncing on a mapping stops comments and status changes in both directions.

When development tracking is on, the Development panel also shows branches, commits and deploys from GitLab. See Deploy webhook and development lifecycle.

  • Could not reach the server: check the address, with no /api/v4 and no http://, and that ProjectBrain can reach it.
  • Certificate not trusted: add your authority’s certificate on the connection screen.
  • A 401 after it worked: the token was changed, expired or revoked. Make a new one and reconnect. If only a merge fails with 401, the problem is your own linked account.
  • Reads work but writes fail: the token lacks the api scope.
  • A webhook was delivered but nothing happened: the GitLab project is probably not mapped, or the secret in GitLab does not match the one on the connection screen.
  • No Merge button: the integration is off, you lack code.merge, or the link cannot be read.
  • GitLab links show only on tasks a person can already see.
  • Clients and outside guests see no GitLab links, statuses or buttons.
  • Screens you lack permission for are not shown.
  • One GitLab server per organization.
  • GitLab does not sign webhooks. A shared secret is the only check.
  • No automated test reaches a real GitLab server, so wording may change as the beta settles.