Skip to main content
Glama
Qaf MCP Server
by qaf-ai

Qaf MCP server and plugins

Qaf connects an AI assistant to a library of 8,500+ classical Arabic books from the Islamic scholarly tradition: Qur’an commentary (tafsir), hadith collections and their commentaries, jurisprudence (fiqh) across the schools, theology, history and Arabic language. Ask in English or Arabic and get passages in the original Arabic, each with its book, author, volume, page and a link to the printed page.

The Qaf MCP server is hosted by Qaf, so there is nothing to install or run. This repository holds its configuration and the Qaf plugin, which bundles the server with a research skill for Claude Code, Cursor, Codex and Antigravity.

Server URL

https://api.qaf.ai/mcp

Transport

Streamable HTTP

Sign-in

OAuth 2.1 with a Qaf account, in the browser. No API key.

MCP Registry

ai.qaf/qaf

Tools

All three tools are read-only.

Tool

What it does

search

Finds passages by meaning and keywords, optionally filtered by author, book, genre or the author's death year.

fetch

Reads a passage with its footnotes and, if asked, up to five passages on each side.

lookup_catalog

Resolves an author or book name to the IDs that search filters take.

Related MCP server: hadith-mcp

Before you connect

You need a Qaf account; create one at https://qaf.ai. The free plan works. The first time you connect, you sign in on qaf.ai and approve access. Each account has a weekly search allowance; reading passages and catalog lookups don't count against it.

Configure

VS Code with GitHub Copilot

Install in VS Code, or add it yourself:

  1. Run MCP: Add Server from the Command Palette and choose HTTP.

  2. Paste https://api.qaf.ai/mcp and enter qaf as the server ID.

  3. Send a message in Copilot Chat to start the server, then sign in with your Qaf account in the browser that opens.

GitHub Copilot CLI

copilot mcp add --transport http qaf https://api.qaf.ai/mcp

Claude Code

To install the plugin, with the server and the research skill:

/plugin marketplace add qaf-ai/plugins
/plugin install qaf@qaf

Then run /mcp, select qaf and sign in.

claude.ai and Cowork

Open Customize › Plugins › Add › Add marketplace and enter qaf-ai/plugins.

Codex

codex plugin marketplace add qaf-ai/plugins
codex plugin add qaf@qaf
codex mcp login qaf

Cursor

Add the server to ~/.cursor/mcp.json, then turn on qaf under Customize and sign in:

{
  "mcpServers": {
    "qaf": {
      "url": "https://api.qaf.ai/mcp"
    }
  }
}

Other clients

Any client that supports remote MCP servers with OAuth sign-in can connect. Most take this configuration:

{
  "mcpServers": {
    "qaf": {
      "type": "http",
      "url": "https://api.qaf.ai/mcp"
    }
  }
}

Steps for more clients, and troubleshooting: https://docs.qaf.ai/mcp/connect

Use it

Ask a question and name a scholar or book if you have one in mind. The assistant resolves the name, searches the library, reads the passages around a result, and cites the book and page for each point. For example:

  • What do classical scholars say about combining prayers while traveling? Cite the books.

  • Find what al-Nawawi wrote about intention (niyyah) in his commentary on Sahih Muslim, then show me the passages around it.

  • ما قول المالكية في المسح على الخفين؟ اذكر المصادر والصفحات.

Passages are in Arabic, and a translation or summary written by an assistant can contain errors, so check the linked page. Qaf returns sources, not rulings. For a ruling on your own situation, ask a qualified scholar.

Documentation and support

About this repository

The plugin is in plugins/qaf. This repository is generated by Qaf's internal listing tool, and each release is a tag vX.Y.Z. It doesn't hold the server's source. We don't accept pull requests.

The files in this repository are MIT-licensed. The Qaf name and logo are trademarks of Qaf LLC, and the library's texts are not covered by this license.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      Provides AI assistants with comprehensive access to Islamic resources including Quran verses with translations, Tafsir commentary, Hadith collections, and audio recitations. Enables users to explore Islamic texts, get daily inspiration, and access scholarly interpretations through natural language queries.
      18
      25 npm
      10
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      Enables fetching and searching canonical hadith texts (Arabic and English) with cross-references and citation-safe URLs for assistants, built on FastMCP.
      3
      GPL 3.0
    • F
      license
      Not graded
      quality
      B
      maintenance
      Enables AI assistants to retrieve canonical Quran text, translations, scholarly tafsir, full-text search, and word-level morphology from verified Quran data.
      -