MCP Catalogs
Home

WikidataMCP

by wmde·24·Score 43

MCP server providing standardized tools to explore and query Wikidata programmatically for AI applications.

knowledge-graphai-llmdeveloper-tools
6
Forks
5
Open issues
this month
Last commit
2d ago
Indexed

Overview

The Wikidata MCP server offers a comprehensive set of tools designed for AI agents and workflows to interact with Wikidata. It includes vector search capabilities for finding entities and properties, statement retrieval for detailed entity information, hierarchy exploration for understanding relationships, and SPARQL query execution for structured data retrieval. The server is well-documented with clear examples and usage guidelines.

Try asking AI

After installing, here are 5 things you can ask your AI assistant:

you:AI agents exploring knowledge relationships in Wikidata
you:Fact-checking systems verifying information against Wikidata
you:Content enrichment by connecting external data to Wikidata entities
you:What search capabilities does this MCP server provide?
you:Can I execute custom SPARQL queries with this server?

When to choose this

Choose WikidataMCP when your AI application needs to explore and query Wikidata programmatically, especially when leveraging semantic search or SPARQL queries.

When NOT to choose this

Don't choose this if you need write access to Wikidata (this is read-only) or if you require more comprehensive Wikidata integration beyond query capabilities.

Tools this server exposes

6 tools extracted from the README
  • search_itemssearch_items(query: str, lang: str = "en") -> str

    Searches Wikidata items using vector search, returning QIDs with labels and descriptions.

  • search_propertiessearch_properties(query: str, lang: str = "en") -> str

    Searches Wikidata properties using vector search, returning PIDs with labels and descriptions.

  • get_statementsget_statements(entity_id: str, include_external_ids: bool = False, lang: str = "en") -> str

    Returns direct statements for an entity in triplet-like text form.

  • get_statement_valuesget_statement_values(entity_id: str, property_id: str, lang: str = "en") -> str

    Returns all statement values for an entity-property pair including qualifiers and references.

  • get_instance_and_subclass_hierarchyget_instance_and_subclass_hierarchy(entity_id: str, max_depth: int = 5, lang: str = "en") -> str

    Retrieves hierarchical context using 'instance of' and 'subclass of' relationships.

  • execute_sparqlexecute_sparql(sparql: str, K: int = 10) -> str

    Executes a SPARQL query against Wikidata and returns up to K rows as CSV.

Comparable tools

wikibase-mcpwikidata-query-apisparql-mcp

Installation

Installation

  1. Run locally:
uv run python main.py
  1. Using Docker:
docker compose up --build
  1. Connect to the public server:
  • Server: https://wd-mcp.wmcloud.org/
  • MCP endpoint: https://wd-mcp.wmcloud.org/mcp

Claude Desktop Configuration

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "wikidata": {
      "command": "curl",
      "args": ["https://wd-mcp.wmcloud.org/mcp"]
    }
  }
}

FAQ

What search capabilities does this MCP server provide?
The server offers both vector search and keyword search for finding Wikidata items (QIDs) and properties (PIDs), with fallback capabilities when vector search isn't available.
Can I execute custom SPARQL queries with this server?
Yes, the server includes an execute_sparql tool that allows running custom SPARQL queries against Wikidata, returning results as CSV text.

Compare WikidataMCP with

GitHub →

Last updated · Auto-generated from public README + GitHub signals.