atlassian-confluence-mcp-server Server

An open-source Model Context Protocol (MCP) server for Atlassian Confluence that lets AI assistants like Claude and Windsurf read, create, search, and manage Confluence wiki pages. Works with Confluence Cloud, on-premise Server, and Data Center deployments — connect your AI coding agent to your team's knowledge base in seconds via npx.

Documentation

Atlassian Confluence MCP Server

CI npm version npm downloads License: MIT

An open-source Model Context Protocol (MCP) server for Atlassian Confluence that lets AI assistants like Claude and Windsurf read, create, search, and manage Confluence wiki pages. Works with Confluence Cloud, on-premise Server, and Data Center deployments — connect your AI coding agent to your team's knowledge base in seconds via npx.

Why atlassian-confluence-mcp-server?

  • ✅ Only MCP server supporting Cloud + Server + Data Center in one package
  • 42 tools — most comprehensive Confluence MCP available
  • ✅ Zero config via npx — no install needed
  • ✅ PAT, Basic Auth, and API token support
  • ✅ Actively maintained with provenance-signed releases

Why use this instead of Atlassian's official MCP server?

FeatureThis packageAtlassian Official
Confluence Cloud
On-premise Server
Data Center
Zero config via npx
42 tools~15 tools
Space management (create/delete)
Page copy/move
Watchers
Permissions/restrictions
Task extraction
Export (PDF/Word)
Open source✅ MIT
Works offline/intranet

Features

  • Space Management — Create, delete, list, and inspect spaces
  • Page CRUD — Create, read, update, delete, copy, and move pages
  • Search — Full CQL and text search, recently modified pages
  • Labels — Add, list, and remove page labels
  • Comments — Read and post page comments
  • Attachments — List page and comment attachments
  • Page Hierarchy — Navigate parent/child relationships
  • Version History — Browse and inspect page versions
  • Watchers — View and manage page watchers
  • Permissions — Get and set page restrictions
  • Tasks — Extract inline tasks from pages
  • Export — Generate PDF/Word export URLs
  • Personal Space — Create pages in your personal space
  • URL Parsing — Retrieve page content from a Confluence URL

Prerequisites

  • Node.js 18+
  • A Confluence instance (Cloud or Server/Data Center 7.9+)
  • Authentication credentials (PAT or username/password)

Installation

Via npx (no install required)

npx atlassian-confluence-mcp-server

Global install

npm install -g atlassian-confluence-mcp-server

From source

git clone https://github.com/anuragagrawal0430/atlassian-confluence-mcp-server.git
cd atlassian-confluence-mcp-server
npm install
npm run build

Configuration

All configuration is passed through environment variables. Never hard-code credentials.

VariableRequiredDescription
CONFLUENCE_BASE_URLYesRoot URL of your Confluence instance
PATSee belowAPI token (Cloud) or Personal Access Token (Server/DC)
CONFLUENCE_USERNAMECloud onlyYour Atlassian account email
CONFLUENCE_PASSWORDAlt authPassword or API token for Basic Auth

Confluence Cloud

Cloud API tokens are generated from your Atlassian account and require both your email and the token:

CONFLUENCE_BASE_URL=https://your-site.atlassian.net
[email protected]
PAT=your-api-token
  1. Go to https://id.atlassian.com/manage-profile/security/api-tokens
  2. Click Create API token, give it a label, and copy the value
  3. Set CONFLUENCE_USERNAME to your Atlassian account email
  4. Set PAT to the copied API token

Confluence Server / Data Center (7.9+)

Server and Data Center instances use a Personal Access Token with Bearer authentication. Only the token is needed:

CONFLUENCE_BASE_URL=https://confluence.example.com
PAT=your-personal-access-token
  1. Navigate to Profile > Settings > Personal Access Tokens
  2. Create a token with the required permissions
  3. Copy the token value

Basic Authentication (fallback)

For older Server versions without PAT support, use username/password:

CONFLUENCE_BASE_URL=https://confluence.example.com
CONFLUENCE_USERNAME=your-username
CONFLUENCE_PASSWORD=your-password

MCP Client Configuration

Cloud (npx)

{
  "mcpServers": {
    "confluence": {
      "command": "npx",
      "args": ["-y", "atlassian-confluence-mcp-server"],
      "env": {
        "CONFLUENCE_BASE_URL": "https://your-site.atlassian.net",
        "CONFLUENCE_USERNAME": "[email protected]",
        "PAT": "your-api-token"
      }
    }
  }
}

Server / Data Center (npx)

{
  "mcpServers": {
    "confluence": {
      "command": "npx",
      "args": ["-y", "atlassian-confluence-mcp-server"],
      "env": {
        "CONFLUENCE_BASE_URL": "https://confluence.example.com",
        "PAT": "your-personal-access-token"
      }
    }
  }
}

Global install

{
  "mcpServers": {
    "confluence": {
      "command": "atlassian-confluence-mcp-server",
      "env": {
        "CONFLUENCE_BASE_URL": "https://confluence.example.com",
        "PAT": "your-personal-access-token"
      }
    }
  }
}

From source

{
  "mcpServers": {
    "confluence": {
      "command": "node",
      "args": ["./dist/index.js"],
      "env": {
        "CONFLUENCE_BASE_URL": "https://confluence.example.com",
        "PAT": "your-personal-access-token"
      }
    }
  }
}

Available Tools (42)

Connection

ToolDescription
confluence_test_connectionTest connection to Confluence API

Spaces

ToolDescription
confluence_get_spacesList all spaces
confluence_get_spaceGet space details by key
confluence_get_space_by_keyAlias for get_space
confluence_create_spaceCreate a new space
confluence_delete_spaceDelete a space and all its content
confluence_get_space_homepageGet the homepage of a space

Pages

ToolDescription
confluence_get_pagesList pages, optionally filtered by space
confluence_get_pageGet page by ID
confluence_get_page_by_titleGet page by title within a space
confluence_create_pageCreate a new page
confluence_update_pageUpdate an existing page
confluence_delete_pageDelete a page
confluence_copy_pageCopy a page, optionally to a different space
confluence_move_pageMove a page to a different parent or space

Search

ToolDescription
confluence_searchSearch using CQL
confluence_search_pagesSearch pages by text
confluence_get_recently_modifiedGet recently modified pages

Labels

ToolDescription
confluence_get_page_labelsGet labels on a page
confluence_add_page_labelAdd a label to a page
confluence_delete_page_labelRemove a label from a page

Comments

ToolDescription
confluence_get_page_commentsGet comments on a page
confluence_add_page_commentAdd a comment to a page

Attachments

ToolDescription
confluence_get_page_attachmentsList attachments on a page
confluence_get_comment_attachmentsList attachments on a comment

Page Hierarchy

ToolDescription
confluence_get_child_pagesGet child pages of a parent
confluence_get_page_ancestorsGet ancestor pages

Version History

ToolDescription
confluence_get_page_versionsGet page version history
confluence_get_page_versionGet a specific page version

Properties

ToolDescription
confluence_get_page_propertiesGet content properties of a page

User

ToolDescription
confluence_get_current_userGet current authenticated user

Watchers

ToolDescription
confluence_get_page_watchersGet users watching a page
confluence_watch_pageAdd current user as a watcher
confluence_unwatch_pageRemove current user as a watcher

Permissions

ToolDescription
confluence_get_page_permissionsGet page restrictions/permissions
confluence_set_page_permissionsSet page restrictions/permissions

Tasks

ToolDescription
confluence_get_page_tasksExtract inline tasks from a page

Export

ToolDescription
confluence_export_pageGet export URL for a page (PDF or Word)

Utilities

ToolDescription
confluence_get_page_by_urlGet page from a Confluence URL

Personal Space

ToolDescription
confluence_get_personal_space_keyGet current user's personal space key
confluence_create_page_in_personal_spaceCreate page in personal space
confluence_create_private_spaceCreate a private space

Resources

URIDescription
confluence://spacesList of all Confluence spaces

Example CQL Queries

# Pages in a specific space
type=page AND space=TEAM

# Pages with a label
type=page AND label=documentation

# Recently modified pages
type=page AND lastModified > now("-7d")

# Title search
type=page AND title~"Meeting Notes"

# Pages created by current user
type=page AND creator=currentUser()

Page Body Format

Pages use Confluence storage format (XHTML):

<p>This is a paragraph.</p>
<h1>Heading 1</h1>
<ul>
  <li>Item 1</li>
  <li>Item 2</li>
</ul>
<ac:structured-macro ac:name="code">
  <ac:parameter ac:name="language">javascript</ac:parameter>
  <ac:plain-text-body><![CDATA[console.log("Hello");]]></ac:plain-text-body>
</ac:structured-macro>

Security

  • Credentials are read exclusively from environment variables — never hard-coded.
  • Input validation — all user-supplied parameters are validated and sanitized before use.
  • CQL injection prevention — user input interpolated into CQL queries is escaped.
  • URL path encoding — all dynamic path segments are encoded with encodeURIComponent.
  • Request timeouts — all HTTP requests have a 30-second timeout to prevent hanging.
  • Error sanitization — API error responses are truncated and stripped of HTML before surfacing.
  • Pagination limits — query limits are clamped to a safe maximum (100) to prevent abuse.

Contributing

Please see CONTRIBUTING.md for guidelines on how to contribute to this project.

Security Policy

For security policies and vulnerability reporting, see SECURITY.md.

Changelog

See CHANGELOG.md for a history of changes.

License

MIT

Acknowledgments