Skip to content
AI Dev Toolkit.
Esc
  • Loading…

MCP server · Code and developer tools

GitLab MCP server

The GitLab MCP server is an MCP endpoint built into GitLab itself. It gives an assistant access to projects, issues, merge requests, pipelines and search. It runs remotely at https://gitlab.com/api/v4/mcp (or your own instance) with OAuth sign-in, and its default tools can push commits, merge and run pipelines with your permissions.

Maintainer
GitLab (official)
Licence
MIT
Runs
Remote (URL)
Sign-in
OAuth sign-in in the app
Registry version
0.0.1 (updated 2025-10-02)
Last activity
2026-10-12

Overview

What can the GitLab MCP server do?

The GitLab MCP server is part of GitLab itself rather than a separate package. Every GitLab.com, Self-Managed and Dedicated instance exposes it at /api/v4/mcp over HTTP. Clients sign in with OAuth 2.0 and register themselves through dynamic client registration, or send a fine-grained personal access token with the MCP tool permission. It is generally available from GitLab 19.5 and included in the Free tier from 19.2. Clients that only speak stdio can connect through mcp-remote.

It suits teams whose code, issues and CI already live in GitLab and who want an assistant to read merge requests, check failing pipelines or file work items. Tools come in toolsets: core, merge_requests, work_items, repository and ci are on by default, while wikis and code_security are opt-in. You choose toolsets with the X-Gitlab-Enabled-Mcp-Server-Toolsets header or name single tools with X-Gitlab-Enabled-Mcp-Server-Tools. Vulnerability tools need GitLab Ultimate, and GitLab Duo agent tools appear only where Duo Agent Platform is available.

Tools

Tools it gives the assistant

  • Create and read issues and work items, and link work items
  • Read, review, comment on and merge merge requests
  • Read repository files, trees, commits, branches and tags, and add commits
  • List, inspect and manage CI/CD pipelines and jobs
  • Search projects, groups, labels and code, including semantic search
  • Opt-in wiki pages and vulnerability tools

Install

How do I install GitLab MCP in Claude Code, Cursor or VS Code?

You need:

  • A GitLab.com account or a GitLab Self-Managed or Dedicated instance (replace gitlab.com in the URL with your host)
  • MCP server access allowed for your top-level group on GitLab.com, or for the instance on Self-Managed and Dedicated
  • Node.js 20 or newer, only if your client needs mcp-remote

Run in your project. --scope local keeps the servers private to you in this project; use user for every project.

Terminal
claude mcp add --scope local --transport http gitlab https://gitlab.com/api/v4/mcp
  • gitlab: if the server needs a sign-in, the app will ask (run /mcp in Claude Code).

Need another app? Open GitLab MCP server in the MCP config generator for a shared project .mcp.json, Devin, or several servers at once; it writes one file per app. The snippets follow the setup in the server’s README, checked on 2026-10-14.

Is the GitLab MCP server safe? Check before you install

  • The default toolsets include write tools such as add_commit, accept_merge_request and manage_pipeline, so the assistant can push commits, merge and run pipelines with your permissions.
  • The docs describe no read-only switch. Narrow what is exposed with the X-Gitlab-Enabled-Mcp-Server-Toolsets or X-Gitlab-Enabled-Mcp-Server-Tools header.
  • Legacy personal, project and group access tokens are rejected with 403. Use OAuth or a fine-grained personal access token scoped to the MCP tool resource.
  • A remote server sees whatever the assistant sends it. Sign in with the narrowest access the service offers. See how to choose a safe server.

FAQ

GitLab MCP questions

Is the GitLab MCP server official?

Yes. GitLab publishes and maintains it, under the MIT licence. Install it only from the source linked on this page, not from a copy in another directory.

Is GitLab MCP server remote or local?

Remote. Your MCP app connects to https://gitlab.com/api/v4/mcp over HTTP, so nothing runs on your machine and the service sees the requests the assistant sends.

Does GitLab MCP server need an API key or account?

Yes, a sign-in. Your MCP app opens an OAuth sign-in to the service the first time it connects, and the server then acts with that account’s permissions. You also need: A GitLab.com account or a GitLab Self-Managed or Dedicated instance (replace gitlab.com in the URL with your host); MCP server access allowed for your top-level group on GitLab.com, or for the instance on Self-Managed and Dedicated; Node.js 20 or newer, only if your client needs mcp-remote.

Why it’s listed

Why we list it

GitLab’s own server, available on every tier and deployment type, with header-based toolset selection for keeping the tool list small.

Related

All MCP serversMCP config generatorGuide: MCP servers in Claude CodeGuide: what is MCP?