Skip to main content
Watch: I Built an AI App Without Leaving Databricks

Developer platforms - official GitLab server

GitLab MCP server

Built-in MCP endpoint on GitLab.com, Self-Managed and Dedicated that lets AI tools read and act on projects, merge requests, work items, repositories and CI/CD pipelines with the user's permissions. GitLab hosts it at https://gitlab.com/api/v4/mcp with OAuth or API key auth.

Last verified 15 tools2 sources

Install

Terminal
claude mcp add -s user --transport http GitLab https://<gitlab.example.com>/api/v4/mcp
Terminal
codex mcp add GitLab --url "https://<gitlab.example.com>/api/v4/mcp"
JSON
{
  "mcpServers": {
    "GitLab": {
       "type": "http",
       "url": "https://<gitlab.example.com>/api/v4/mcp"
    }
  }
}

Generic

JSON
{
  "mcpServers": {
    "GitLab": {
      "type": "http",
      "url": "https://<gitlab.example.com>/api/v4/mcp"
    }
  }
}

Tools

get_project
Returns metadata for a single GitLab project: numeric ID, full path, default branch, visibility, and web URL.
list_projects
Lists projects visible to the user
save_merge_request
Creates or updates a merge request in a GitLab project.
get_merge_request
Retrieves a merge request and, optionally, its diffs, commits, notes, pipelines, discussions, approvals, or conflicts.
list_merge_requests
Lists or searches merge requests in a GitLab project or group, returning compact merge request metadata.
save_note
Adds a comment to a GitLab merge request or work item, or replies to an existing discussion thread, as the authenticated user.
save_work_item
Creates or updates a GitLab work item, such as an issue, task, or epic.
list_work_items
Lists or searches work items (issues, incidents, tasks, epics and more) in a group or project.
add_commit
Adds a commit with one or more file actions to a branch in a single call.
list_branches
Lists the branches of a GitLab project, optionally filtered by name.
get_repository_file
Retrieves the contents of a single file from a repository at a specific ref.
get_pipeline
Retrieves a pipeline, and optionally its jobs, downstream pipelines, bridge (trigger) jobs, or the artifacts its jobs produced.
get_job
Gets a CI/CD job's metadata, and optionally its trace/log or the artifacts it produced.
search
Searches for a term across the entire GitLab instance with the search API.
start_duo_session
Starts an asynchronous GitLab Duo Agent Platform session to accomplish a goal in a project.

As documented on October 17, 2026. A running server reports its current list through tools/list.

Notes and caveats

  • Generally available as of GitLab 19.5 (experiment in 18.3, beta in 18.6); available on Free, Premium and Ultimate since 19.2.
  • Replace <gitlab.example.com> with gitlab.com or your instance URL.
  • Access must be allowed per top-level group on GitLab.com or per instance on Self-Managed/Dedicated.
  • Auth: OAuth token with the mcp scope (dynamic client registration or a pre-registered app) or a fine-grained PAT with the MCP tool permission; legacy PATs and project/group tokens are rejected. stdio is supported only via the mcp-remote proxy (Node.js 20+).
  • VS Code setup is documented as UI steps (MCP: Add Server, HTTP, the URL) rather than a snippet.
  • Toolsets selectable via X-Gitlab-Enabled-Mcp-Server-Toolsets header; duo_agent_platform and code_security tools need the corresponding licensed features.
  • GitLab.com rate limits are 60 requests per minute on Free and 600 on Premium/Ultimate.
  • Server code ships inside the GitLab monorepo, which mixes MIT and GitLab EE licensing, so no single license is listed.

FAQ

What does the GitLab MCP server do?

Built-in MCP endpoint on GitLab.com, Self-Managed and Dedicated that lets AI tools read and act on projects, merge requests, work items, repositories and CI/CD pipelines with the user's permissions. The vendor documents 15 tools, including get_project, list_projects, save_merge_request and get_merge_request.

How do I add the GitLab MCP server to Claude Code?

Run claude mcp add -s user --transport http GitLab https://<gitlab.example.com>/api/v4/mcp, copied from GitLab's docs. This page also has snippets for Codex, Cursor and Generic.

Does the GitLab MCP server need authentication?

Yes, OAuth or API key. Transport: Streamable HTTP. Status: GA, last checked October 17, 2026.

Sources

Last verified against 2 GitLab pages, then re-checked independently.

Newsletter

New MCP servers, the week they ship

One email per week. New official MCP servers, the coding tools that support them and how developers wire them up.