Anyquery MCP

A SQLite-based SQL engine with plugins for apps, databases and files: the anyquery mcp command exposes that data to Claude, Cursor and other MCP clients

  • 1,784 ★ on the repository
  • Last commit
MCP server

Broad access

Why this level

  • The server executes SQL written by the model over data from connected apps and databases
  • The gpt mode opens an internet tunnel, while MCP mode requires a token and turns on the sandbox when it is exposed to the network
All reasons and checks

julien040/anyquery

Install

Manual install

brew install anyquery

APT, YUM, Scoop, Winget, Chocolatey and the curl -fsSL https://anyquery.dev/install.sh | sh script for macOS and Linux are also available.

Access and checks

How we review

Broad accessThe tool can change data, run commands or handle secrets.

  • The server executes SQL written by the model over data from connected apps and databases
  • The gpt mode opens an internet tunnel, while MCP mode requires a token and turns on the sandbox when it is exposed to the network

This is third-party code. Review the repository files before installing.

What it does

Anyquery is a Go program that runs SQL queries over files, databases and apps. It is built on SQLite, and sources attach through plugins from a registry; the docs cite GitHub, Notion, Airtable, Apple Notes, Chrome and Todoist as examples. Files can be queried directly, and the MySQL server mode (anyquery server) lets TablePlus or Metabase connect. The anyquery mcp command starts an MCP server. Over stdio the client launches it, over HTTP it listens on localhost:8070 with /mcp for Streamable HTTP and /sse for the legacy transport. HTTP authorization by token is on by default, and the token can be set with the ANYQUERY_AI_SERVER_BEARER_TOKEN variable. The agent writes SQL and receives tables with data from the connected sources. The --readonly flag opens the database in read-only mode. The --sandbox flag restricts query execution, and the sandbox turns on by itself when the server is exposed to the network (--tunnel or a non-loopback --host). The anyquery gpt command opens a similar HTTP server for ChatGPT and other clients with function calling.

Who it is for. For people who want to ask Claude, Cursor or ChatGPT about data spread across several services and files and are fine with plugging them into one SQL database.

Good fit when

  • Your data sits in different apps such as Notion, Airtable and GitHub, and you want to ask across them with one SQL query
  • You want the agent to treat local CSV, JSON, Parquet, YAML or TOML files as tables: the repo has dedicated readers for them
  • You want the agent to reach notes or browser data (Apple Notes, Chrome) for selections and summaries
  • You need a MySQL-compatible entry to the same data for TablePlus or Metabase while the agent uses MCP
  • You want to limit what the agent can do to reading: start anyquery mcp with the --readonly flag

Not a fit when

  • You need MCP for a single PostgreSQL or MySQL database: a dedicated server for that engine is simpler
  • AGPLv3 for the engine core is a problem for you, for instance when embedding it in a closed product
  • You only need to fetch a web page or call a REST API: Anyquery is overkill for that
  • You cannot install binaries and packages through brew, apt, winget, Scoop or Go on the machine

Example request

From my Notion tasks table, select every card with the status "in progress" and group them by assignee.

MCP

Transport
stdio, http, sse
Authentication
key is optional

Environment variables

ANYQUERY_AI_SERVER_BEARER_TOKEN secret
Bearer token for HTTP connections. If unset, the server generates a random one and shows it at startup.

Limitations

  • The core is licensed under AGPLv3, the RPC library for plugins under MIT, and each plugin has its own license.
  • The MCP server executes the SQL that the model writes, so use --readonly and --sandbox for sensitive data.
  • Building from source needs Go 1.26 or newer and a C compiler because the engine uses cgo.
  • One person maintains the project, and the author accepts only minor contributions.

How to disable. Remove the anyquery entry from your client's MCP config. If you started the server by hand, stop the anyquery mcp process. The program itself is removed with the package manager you used, for example brew uninstall anyquery.

FAQ

How do I connect Anyquery to Claude or Cursor over MCP?

Install the program and add an MCP server with the command anyquery mcp --stdio: the client launches it itself. For network access there is an HTTP mode on 127.0.0.1:8070 with a token that is printed at startup.

What is Anyquery and which data can it query?

It is a SQL engine on SQLite that reads files, databases and apps through plugins from a registry. The docs list Apple Notes, Notion, Chrome, Todoist, GitHub and Airtable as examples. The core is written in Go.

Can the agent change data through Anyquery?

The agent sends SQL and the query runs as written. For protection start the server with --readonly and --sandbox. The sandbox switches on by itself when the server is reachable over the network via --tunnel or a non-local --host.

Does Anyquery work with ChatGPT?

Yes. The anyquery gpt command starts an HTTP server for function-calling clients and opens an internet tunnel by default. It prints an ID to paste into the client. For local use set --host or --port.

How do I install Anyquery on macOS, Linux and Windows?

On macOS brew install anyquery works, and on Linux and macOS there is the curl -fsSL https://anyquery.dev/install.sh | sh script. Linux also has APT, YUM and AUR, Windows has Scoop, Winget and Chocolatey. Building with go install needs Go 1.26 and a C compiler.

Discussion

No questions or reviews yet.

Official

A desktop SQL workspace with a built-in MCP server: the agent reads the schema and runs queries in the same client you already use

MCP serverBroad access5.3KRepository stars

A Python MCP server for MySQL: listing tables, reading data, running SQL and inspecting schema through a controlled interface

MCP serverBroad access1.4KRepository stars

MCP server that gives an agent access to MySQL: schema inspection and queries, read-only by default, writes behind flags

MCP serverExtended access2.2KRepository stars

MCP SQLite Server (npx)

MCP SQLite Server

Node.js MCP server for SQLite databases that runs via npx, no Python or uvx needed

MCP serverExtended access17Repository stars

pgEdge Postgres MCP

pgEdge Postgres MCP Server

Postgres MCP in Go with read-mode queries, EXPLAIN plans, semantic search, several databases and a ready chat client and web interface

MCP serverExtended access239Repository stars
Editors’ pick

A token-lean MCP server for PostgreSQL, MySQL, MariaDB, SQL Server and SQLite with a read-only mode

MCP serverBroad access3.7KRepository stars

Comparison with similar tools

Entries that share the main search query, and how they differ.

EntryOfficialAuthenticationRepository starsMain difference
Anyquery (this entry)nokey is optional1,784
DBHubnonot required3,703a universal MCP server for relational databases, while Anyquery brings apps and files into SQL as well
MCP Toolbox for Databasesyesnot required16,705Google's server for databases, while Anyquery focuses on plugins for apps and files

README in short

The README presents Anyquery as a SQLite-based SQL engine for files, databases and apps with plugins. It then covers three uses: connecting an LLM over MCP, a SQL shell in the terminal and a MySQL server for familiar clients. The install section lists Homebrew, APT, YUM, Scoop, Winget, Chocolatey, AUR, a quick script for macOS and Linux, and go install. It closes with plugins, sponsors and the license.

README badge

Report a problem

Foxx AIAnyquery
Foxx AI

I am Foxx AI and I have already vetted this tool. Ask about install, setup or anything else, and I will keep it simple.