GitLab MCP Server
✓ verifiedManage GitLab projects, issues, and merge requests.
Don't have ToolPiper? We'll take you to the download.
Publisher
License
MIT
Transport
Local subprocess
Tools
5
What this server does
Nine tools cover the parts of GitLab you actually touch from a code chat: read a file with `get_file_contents`, commit a single file with `create_or_update_file`, batch-commit multiple files with `push_files`, file an issue, open a merge request, fork a project, create a branch, search projects, and create a new repository. Multi-file pushes batch into one commit, which keeps history clean. Branches you reference are created automatically if they do not exist. That is convenient and also a footgun: be aware before letting the model commit on a branch name it invented. Self-hosted GitLab works via the optional `GITLAB_API_URL` (default `https://gitlab.com/api/v4`). Token scopes: `api` for full read/write, `read_api` for browsing only, or the narrower `read_repository` + `write_repository` if you want repo-only access without project administration. Create one at gitlab.com/-/user_settings/personal_access_tokens. Compared to the GitHub server: same shape, narrower surface. No PR review tools, no CI controls, no notifications, no labels API beyond what `create_issue` accepts. For deeper GitLab work the community projects go further, but this reference covers the file, issue, and MR loop cleanly and preserves git history without force-pushing. Operations either succeed or return a clear error.
Tools included
create_or_update_file
Create or update a file in a repository.
search_repositories
Search GitLab projects.
create_issue
Open an issue in a project.
create_merge_request
Open a merge request.
get_file_contents
Read a file at a path.
The authoritative list comes from the server's tools/list at runtime. This catalog entry may lag the upstream until the next ToolPiper release.
Install in ToolPiper
ToolPiper handles the JSON configuration. Click Install, fill in any required tokens, and the server is ready in your chat.
Don't have ToolPiper? We'll take you to the download.
Install in another client
Install in another MCP client (Claude Desktop, Cursor, Continue, Cline)
Add this to ~/Library/Application Support/Claude/claude_desktop_config.json.
{
"mcpServers": {
"gitlab": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-gitlab"
]
}
}
}Example prompts
"Open an issue in modelpiper/web titled 'CSP blocks third-party fonts' with label 'bug'."
"Create a merge request from feature/auth into main: 'Rewrite auth middleware'."
"Read .gitlab-ci.yml from the dev branch of modelpiper/api."
"Fork modelpiper/sandbox into my namespace and create branch fix/typos."
Security notes
The personal access token is the whole authorization story. A token with `api` scope can read, write, and delete anything your user can. Treat it like a password and rotate at gitlab.com/-/user_settings/personal_access_tokens if it leaks. For self-hosted GitLab, the same applies plus whatever IP allowlist you maintain. The token is passed via the `GITLAB_PERSONAL_ACCESS_TOKEN` env var; do not commit the JSON config to a public repo. The upstream Anthropic reference is archived and GitLab has not published an official MCP server yet, though active community forks exist for users who outgrow this surface.
Related tools
GitHub
✓ verifiedCreate issues, manage pull requests, and search repositories from your AI assistant.
Developer ToolsLocal subprocess5 toolsGitHub (Remote)
✓ verified MAXOAuth-protected GitHub MCP. Manage repos, issues, and pull requests with no token to copy.
Developer ToolsRemote HTTP5 toolsGit
✓ verifiedRead, search, and manipulate Git repositories on disk.
Developer ToolsLocal subprocess5 toolsEverything
✓ verifiedReference test server exercising every MCP feature.
Developer ToolsLocal subprocess5 tools