Skip to content
Skillpedia
● Free and open sourceπŸ’» LocalπŸ”“ No API keyWork and productivity

MediaWiki MCP Server

Lets your AI agent read, search and edit pages on any MediaWiki wiki, including Wikipedia.

147 stars on GitHubby Professional WikiLicense MITUpdated 18 days ago

How to install

This MCP is local: it runs on your computer.

It works in apps installed on your PC (Claude Desktop, Claude Code, Cursor, VS Code…). Choose your app:

Paste in the terminal:

claude mcp add mediawiki -- npx -y @professional-wiki/mediawiki-mcp-server

What to fill in

NameWhat it isRequired
CONFIGPath to your configuration fileNo
MCP_ALLOW_STATIC_FALLBACKSet to 'true' to allow HTTP startup when config.json has static credentials. Otherwise the server refuses to start, preventing silent shared-identity fallback for unauthenticated requests.No
MCP_CONTENT_MAX_BYTESByte cap for the content bodies and result blocks tools return (wikitext, rendered HTML, diffs, statement and row listings). An oversized response is truncated with a trailing marker describing what was left out.No
MCP_FILE_DATA_MAX_BYTESHard cap on the base64-encoded size of a get-file-data response. A transport/safety backstop; callers tune actual size with the tool's width parameter. Over-cap responses error rather than truncate.No
MCP_LOG_LEVELMinimum severity for logger output (stderr telemetry and sendLoggingMessage broadcast). Invalid values fail loudly on first log call.No
MCP_MAX_REQUEST_BODYMaximum HTTP request body size on the StreamableHTTP transport. Accepts size strings like 1mb or 512kb.No
MCP_METRICSSet to 'true' to expose Prometheus metrics at GET /metrics on the HTTP transport. Has no effect on the stdio transport.No
MCP_OAUTH_ALLOWED_REDIRECTSAdditional allowed redirect URIs for hosted-proxy client registration: comma-separated exact URIs (which must include a host) and https prefix patterns ending in /*. Loopback, claude.ai, and verified first-party clients (ChatGPT, Cursor, VS Code) are always allowed; unset means no additional clients.No
MCP_OAUTH_CIMD_ALLOWED_HOSTSComma-separated additional client_id document hosts trusted for CIMD (bare host or host:port). Verified first-party hosts are always trusted.No
MCP_OAUTH_CREDENTIALS_FILEOverride the default OAuth credentials store path. Default: ~/.config/mediawiki-mcp/credentials.json on Linux/macOS, %APPDATA%\mediawiki-mcp\credentials.json on Windows.No
MCP_OAUTH_NO_BROWSERSet to '1' to skip launching a browser during the OAuth dance and log the auth URL to stderr instead. Useful in headless environments and CI.No
MCP_OAUTH_PROXY_STORE_FILEPath to the hosted OAuth proxy's encrypted state file, which lets sign-ins survive restarts. Default: proxy-store.enc under the mediawiki-mcp config dir; /app/data/proxy-store.enc in the Docker image.No
MCP_PUBLIC_URLOverride the request-derived public URL used in the protected-resource discovery doc and WWW-Authenticate header. Set this when running behind a proxy that rewrites the request Host.No
MCP_SHUTDOWN_GRACE_MSMaximum milliseconds to wait for in-flight /mcp calls to drain on SIGTERM/SIGINT before exiting. Capped at 600000.No
MCP_TRANSPORTType of MCP server transportNo
MCP_UPLOAD_MAX_BYTESMemory cap on the server-side fetch used by upload-file-from-url and update-file-from-url. Files larger than this are routed to the wiki's own copy-upload instead of being buffered by the server. Guards this server's memory, not the wiki's $wgMaxUploadSize.No
MCP_USER_AGENTReplaces the User-Agent header of every outbound request, which defaults to mediawiki-mcp-server/<version> (https://github.com/ProfessionalWiki/MediaWiki-MCP-Server). If you set it, give a name and an email or URL, e.g. 'ExampleBot/1.0 (bot@example.org)'.No
PORTPort used for StreamableHTTP transportNo

Ready! Now test it

Restart the app and paste one of these requests in the chat:

Search the wiki for pages about our release process.
Show the last 10 edits to the Installation page.

What it is

This server connects your AI agent to any wiki that runs MediaWiki. The agent can search and read pages, compare revisions, browse categories and files, and, when you sign in, create, edit, move and upload. It can work with several wikis and has extra tools for NeoWiki, Semantic MediaWiki, Cargo, Bucket and Wikibase.

What it can do

  • search-page: full-text search of a wiki
  • get-page: fetch a page
  • get-page-history: list recent revisions
  • compare-pages: diff two versions
  • get-category-members: list pages in a category
  • create-page: create a page (needs sign-in)
  • update-page: edit a page (needs sign-in)
  • upload-file: upload a file (needs sign-in)

When to use

  • β€ΊWhen you want your agent to look something up on a wiki
  • β€ΊWhen you maintain a wiki and want help editing or moving pages
  • β€ΊWhen you want to compare two versions of a page

What you need

Node.js. A config.json file is only needed for private wikis or tools that require sign-in. Writes use OAuth, which you approve in a browser.

Skills that pair well

⭐ Skillpedia MCP Β· freeYour agent finds the right skill on its ownInstall our MCP and your agent searches 15,000+ skills whenever it needs one.Install for free β†’

Frequently asked questions

Is it free?

Yes. The package is on npm and the readme shows an open source license badge.

Do I need to log in?

Not for reading public wikis. Tools marked with a lock need authentication.

Can it work with more than one wiki?

Yes. Each tool takes an optional wiki argument, and you list wikis in the config file.

Can I stop it from making changes?

Yes. Write tools are refused on a wiki with readOnly set to true.

Which extensions are supported?

NeoWiki, Semantic MediaWiki, Bucket, Cargo and Wikibase tools register only on wikis where the extension is installed.

Is it made by MediaWiki?

No. It is made by Professional Wiki.

If it does not work

  • β€ΊCreate a config.json when using a private wiki, and set CONFIG to its path if it is elsewhere.
  • β€ΊFor OAuth on a server without a browser, set MCP_OAUTH_NO_BROWSER=1 and open the logged URL.
  • β€ΊIf responses are cut off, raise MCP_CONTENT_MAX_BYTES.

5 new skills a week. 1 minute to read.