Intermediate 13 minMCP

MCP data.gouv: query public data

BestLLMfor — MCP data.gouv — Public data
Direct response

The data.gouv MCP is the official Model Context Protocol server for data.gouv.fr: it lets an AI assistant search and read French public data in natural language. The public instance https://mcp.data.gouv.fr/mcp is free, requires no API key, is read-only, and connects to Open WebUI, LM Studio, Jan, Claude, or ChatGPT (paid plans only). Version 1.0.3 from November 16, 2026, still experimental.

Since November 2025, data.gouv.fr has published an MCP server that turns its dataset catalog into tools an AI assistant can use. This guide shows you how to connect it to a local model or an online assistant, how to self-host it, what data goes online, and where its capabilities end. You'll be able to choose the right setup and verify that the figures you get actually come from public data.

By Mohamed Meguedmi·Update 2026-12-02·Tested on Windows, macOS, and Linux

#What is the data.gouv MCP?

The data.gouv MCP is the official Model Context Protocol server for data.gouv.fr, France's national open public data platform. This server gives an AI assistant tools to search for datasets, read their files, and query the cataloged public APIs, starting from a question asked in French.

The Model Context Protocol (MCP) is an open protocol that lets an AI application call external tools in a standardized way. An MCP server describes its tools; the client application (Open WebUI, LM Studio, Claude, etc.) offers them to the model, which decides when to call them. The site's guide to the MCP protocol covers this mechanism in detail; this guide focuses on the data.gouv.fr server.

The data.gouv.fr server is developed in Python by the platform team and published under the MIT license on GitHub. According to its changelog, the first version (0.1.0) dates from November 25, 2025, and version 1.0.3, the most recent as of November 18, 2026, from November 16, 2026. The official data.gouv.fr guide still presents it as an experiment whose scope, uses, and configuration may change.

The data.gouv MCP at a glance (verified November 18, 2026)
ItemValueSource
Public instance URLhttps://mcp.data.gouv.fr/mcpdatagouv-mcp repository README
AccessOpen to everyone, no restrictionsRepository README
API keyNone: read-only toolsREADME and data.gouv.fr guide
TransportStreamable HTTP only (neither STDIO nor SSE)Repository README
Code licenseMITRepository README
Latest version1.0.3 from November 16, 2026Repository CHANGELOG
StatusExperimentalOfficial data.gouv.fr guide

#What can the data.gouv MCP do?

The complete kit for building your own AI copilot.

Benefit from our experience and a guided path to build your local copilot and get comfortable with your coding assistant.

  • Lifetime online access
  • PDF + files
  • Refunded within 30 days

The data.gouv MCP can search the data.gouv.fr catalog, describe a dataset and its files, read rows from a CSV or Excel table, explore the listed public APIs, and display visit statistics. The repository README lists ten tools, all read-only: the server doesn't create or modify any content.

search_datasets
Searches datasets by keyword and returns the title, description, organization, tags, and number of files.
search_organizations
Lists or searches publishing organizations: public services, local governments, nonprofits, or companies.
get_dataset_info and list_dataset_resources
Return a dataset's full metadata (license, dates, publisher) and the list of its files with format, size, and URL.
get_resource_info and query_resource_data
Describe a file, then read its rows through the data.gouv.fr tabular API, page by page.
search_dataservices, get_dataservice_info, and get_dataservice_openapi_spec
Find a public API cataloged on data.gouv.fr (for example, the API Adresse or the API Sirene, both mentioned in the README), then summarize its endpoints and parameters.
get_metrics
Returns monthly visits and downloads for a dataset or file.

The README gives sample questions such as "What datasets are available on real estate prices?" The workflow the repository recommends has three steps: find the dataset, list its files, then read a 20-row sample to understand the structure before going further.

#How do you connect the data.gouv MCP to a local LLM?

To use the data.gouv MCP with a model running on your machine, add the address https://mcp.data.gouv.fr/mcp to an MCP-compatible client application: Open WebUI, LM Studio, Jan, AnythingLLM, or OpenCode. The official data.gouv.fr guide documents each of these applications; no key is required.

The requirement on the model side is tool calling (or function calling): the model must be able to produce a structured call request and read the response. Without this capability, the model can't use the server and answers from memory. For reference, the official gpt-oss-20b model card states native function calling and operation within 16 GB of memory; this is information from OpenAI, not a measurement on the data.gouv MCP.

Local apps compatible with the data.gouv MCP, according to the official data.gouv.fr guide (November 18, 2026)
ApplicationWhere to configure the serverStated requirement
Open WebUISettings, Admin, Integrations, External Tool ServersVersion 0.6.31 or later; administrator account
LM StudioProgram tab, Install, Edit mcp.jsonVersion 0.3.17 or later
JanSettings, MCP Servers, Add MCP ServerTransport set to HTTP
AnythingLLManythingllm_mcp_servers.json fileStreamable type
OpenCodeopencode.json fileRemote type

#With Open WebUI and Ollama

  1. 01
    Open the Open WebUI integrations
    Sign in to Open WebUI with an admin account (version 0.6.31 or later), then open Settings, Admin, Integrations.
  2. 02
    Add the connection to the MCP data.gouv server
    Under External Tool Servers, click Add Connection. Set Type to MCP (Streamable HTTP), enter https://mcp.data.gouv.fr/mcp in Server URL, set Auth to None, then click Save.
  3. 03
    Enable the tool in a conversation
    In a new conversation, open the + menu, then Integrations and Tools, and enable the data.gouv.fr server. Choose a Ollama model that can call tools.
  4. 04
    Ask a first question
    For example, ask which datasets data.gouv.fr publishes about EV charging stations. The response should show a call to the search_datasets tool and cite real dataset titles.

#With LM Studio, Jan, AnythingLLM, or OpenCode

In LM Studio, open the Program tab in the right sidebar, click Install, then Edit mcp.json, and add the block below. The same syntax works on macOS, Windows, and Linux, since LM Studio edits the file itself.

LM Studio, mcp.json file (macOS, Windows, Linux)
{
  "mcpServers": {
    "datagouv": {
      "url": "https://mcp.data.gouv.fr/mcp"
    }
  }
}

In AnythingLLM Desktop, the anythingllm_mcp_servers.json file is located in the app's storage/plugins folder: ~/Library/Application Support/anythingllm-desktop on macOS, ~/.config/anythingllm-desktop on Linux, and AppData\Roaming\anythingllm-desktop on Windows. Add the following configuration to it, then restart the app if the server doesn't appear.

AnythingLLM Desktop, anythingllm_mcp_servers.json (macOS, Windows, Linux)
{
  "mcpServers": {
    "datagouv": {
      "type": "streamable",
      "url": "https://mcp.data.gouv.fr/mcp"
    }
  }
}

In Jan, open Settings, MCP Servers, click Add MCP Server, set Transport to HTTP, and paste the server URL into the Command / URL field; a green indicator confirms it's enabled. For the OpenCode coding agent, the configuration goes in opencode.json, for example ~/.config/opencode/opencode.json or at the project root.

OpenCode, opencode.json (macOS, Windows, Linux)
{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "datagouv": {
      "type": "remote",
      "url": "https://mcp.data.gouv.fr/mcp",
      "enabled": true
    }
  }
}

#The data.gouv MCP with Claude, ChatGPT, or Mistral

The data.gouv MCP also works with online assistants, but plan requirements differ. According to the repository README consulted on November 18, 2026, Claude supports it on all plans (only one custom connector on the free plan), ChatGPT only on the paid Plus, Pro, Team, and Enterprise plans, and Mistral Vibe on all its plans, including free.

With these assistants, the conversation and the data read are processed by the vendor's model, in its cloud: the opposite of local AI. Public servants also have access to L'Assistant, the DINUM platform, where the data.gouv.fr connector is already available. For Claude Code, a single command does the job, and it's the same on macOS, Windows, and Linux.

Claude Code (macOS, Windows, Linux)
claude mcp add --transport http datagouv https://mcp.data.gouv.fr/mcp

#Self-hosting the data.gouv MCP server

You can run the data.gouv MCP server on your own machine with Docker, using three commands documented in the README. The server then listens on port 8000 and, by default, queries the production data.gouv.fr platform: self-hosting brings the server closer to you, but the data is still read online.

macOS or Linux terminal, Windows with Docker Desktop
git clone git@github.com:datagouv/datagouv-mcp.git
cd datagouv-mcp
docker compose up -d

The clone command in the README uses SSH and assumes you have an SSH key registered on GitHub. Once the container is running, the address to give your client app is http://127.0.0.1:8000/mcp instead of the public address. The MCP_PORT variable changes the port, DATAGOUV_API_ENV=demo switches to the demo platform, and docker compose down stops the server.

!
Listen address of the self-hosted server
According to the README, the server listens on 0.0.0.0 by default, meaning on all network interfaces, and the repository recommends MCP_HOST=127.0.0.1 for local development, especially for manual installation with uv run main.py. With Docker, the repository's docker-compose.yml file publishes port 8000 on the host machine without restricting the address. On a shared network, block this port at the firewall for other machines.

Self-hosting is mainly useful in three cases: pinning a specific server version, working on the demo platform, or keeping your calls from going through the public instance and its usage statistics.

#What gets sent online with the data.gouv MCP?

With a local model, your conversation stays on your machine, but each tool call sends the MCP server the request the model formulated: search terms, dataset ID, page number. The returned rows then enter the local model's context.

The repository changelog states that version 1.0.3, released November 16, 2026, sends the client software identifier (user agent) to Matomo, the audience measurement tool, and counts server initializations even without any tool call. For its part, data.gouv.fr's « Notre approche de l'intelligence artificielle » page states that it neither collects nor stores personal data through these features.

What leaves your machine depending on the configuration (based on the repository's README and CHANGELOG, November 18, 2026)
ConfigurationConversationTool requestsUsage statistics
Local model + public instanceStays localSent to mcp.data.gouv.frMeasured by the public instance (Matomo)
Local model + self-hosted serverStays localSent to the data.gouv.fr APIs by your serverNot documented in the README for a private instance
Claude, ChatGPT, or Mistral + public instanceProcessed by the assistant's vendorSent to mcp.data.gouv.frMeasured by the public instance (Matomo)

For questions about public data, this flow rarely causes problems. It matters more if your questions reveal a confidential project, such as a list of municipalities targeted for a new site: in that case, phrase your queries neutrally. The self-hosted server bypasses the public instance and its usage statistics, but your search terms are still sent to the data.gouv.fr APIs, since that is where the server reads the data.

#What are the limitations of the data.gouv MCP?

The data.gouv MCP reads excerpts, not entire databases, and the final answer depends on the model interpreting those excerpts. The official guide notes that answers may be incomplete, wrong, or made up, and recommends the data.gouv.fr APIs for applications, visualizations, and automated processing.

Readable file size
The query_resource_data tool uses the tabular API, which according to the README is limited to CSV files of up to 100 MB and XLSX files of up to 12.5 MB.
Rows per call
20 rows per page by default and 200 at most. For a file with tens of thousands of rows, the model only sees a sample, unless it paginates at length.
Formats
Row-by-row reading targets CSV and Excel spreadsheets. For other formats, the server provides the raw file's URL, which you download and process separately.
Local model context
Each page of results consumes tokens. A local model configured with a small context window may lose the start of the conversation after a few calls.
Experimental status
data.gouv.fr warns that the scope and configuration may change: the tool names in this guide are those in the README as of November 18, 2026.
→
Have the figures checked
Ask the model to cite the identifier of the dataset and file used for each figure. You can then open the corresponding page on data.gouv.fr and check the value, the last update date, and the license before any reuse.

#How do you check that the data.gouv MCP is working?

The data.gouv MCP is working when the application shows a tool call, followed by a response that cites real datasets. Without a visible tool call, the model is answering from memory and may make up titles or figures: in that case, the response is worthless as a source.

  1. 01
    Check the server status
    The README documents a /health check endpoint: opening https://mcp.data.gouv.fr/health in a browser should return an ok status. For a self-hosted server, open http://127.0.0.1:8000/health.
  2. 02
    Check that the tool is enabled
    In the client app, the data.gouv.fr tool must be enabled for the current conversation: the green indicator in Jan, the Tools toggle in Open WebUI, the tool list in LM Studio.
  3. 03
    Ask a verifiable question
    Ask for a specific dataset, such as first names given in France or EV charging stations, and require its identifier. A correct answer mentions the call to search_datasets and a title you can find on data.gouv.fr.
  4. 04
    Compare with the website
    Open the dataset page on data.gouv.fr and compare the publisher, the last-updated date, and one or two values read by the model.
i
MCP servers and caution
The LM Studio documentation warns never to install an MCP server from an untrusted source. For data.gouv.fr, use the address published by the platform itself, not a copy found in an MCP server directory.
Frequently asked questions
Is the data.gouv MCP free?+
Yes. The data.gouv MCP is available for free at https://mcp.data.gouv.fr/mcp, with no account or API key, and its code is released under the MIT license. Any cost comes from the assistant you use: ChatGPT requires a paid plan to add a connector, whereas a local model in Open WebUI, LM Studio, or Jan costs nothing extra.
Do you need a data.gouv.fr API key for the MCP server?+
No. The data.gouv.fr MCP server only exposes read-only tools, which is why no API key is needed, according to its README. A data.gouv.fr key is only used to publish or modify content, for example with the datagouv command-line tool, which the MCP server does not do.
Does the MCP data.gouv server work with Ollama?+
Yes, through an MCP-compatible interface such as Open WebUI, which adds the data.gouv.fr server as a tool and makes it available to Ollama models. The chosen model must support tool calling; without it, the model answers from memory instead of querying the catalog.
Can the MCP data.gouv server publish or modify data?+
No. The data.gouv.fr MCP server only offers read tools: search, description, row reading, statistics. The changelog shows that a dataset creation tool was removed because it required key-based authentication. To publish, you need to go through the website or the APIs with an account.
What data can you find with the MCP data.gouv server?+
The MCP data.gouv server gives you access to the data.gouv.fr catalog: datasets published by the French government, local authorities, public institutions, and other producers, as well as public APIs listed on the platform, such as the API Adresse or the API Sirene. Coverage depends on what each producer publishes and keeps up to date.
Can you trust the figures the AI provides via data.gouv.fr?+
Not without checking. The official data.gouv.fr guide warns that answers may be incomplete, wrong, or made up. The model reads only a sample of 20 to 200 rows per call. Ask for the source file's identifier and check the value on the data.gouv.fr page before reusing it.

#Sources and verification as of November 18, 2026

The server address, tools, limits, per-app requirements, and version history were reviewed on November 18, 2026, against the official datagouv-mcp repository and the data.gouv.fr guides; since the service is experimental, these details may change from one version to the next.

Did this guide help you?

Feedback, an error, or a clarification? Let us know—it improves the guide for everyone.