View current Meilisearch connection URL and API key status
Update URL and/or API key to connect to a different instance
Create a new index with optional primary key
List all available indexes
Get detailed metrics for a specific index
Retrieve documents from an index with pagination
Add or update documents in an index
Flexible search across single or multiple indices with filtering and sorting options
View current settings for an index
Update index settings (ranking, faceting, etc.)
List all API keys
Create new API key with specific permissions
Delete an existing API key
Get information about a specific task
List tasks with optional filters
Cancel pending or enqueued tasks
Delete completed tasks
Basic health check
Comprehensive health status
Get Meilisearch version information
Get database statistics
Get system-level information
Meilisearch MCP provides a comprehensive interface for managing and querying Meilisearch instances directly through LLM interfaces like Claude. It enables full control over index and document management, settings configuration, and search operations without leaving your AI assistant. With this MCP, you can create and manage indices, add and retrieve documents, perform complex searches with filtering and sorting, and monitor system health. The dynamic connection configuration allows you to switch between different Meilisearch instances at runtime, making it flexible for various development and production environments.
Meilisearch MCP allows you to interact with Meilisearch, a powerful open-source search engine, directly through LLM interfaces. This integration enables you to manage your search infrastructure, perform queries, and handle administrative tasks without switching contexts.
pip install meilisearch-mcp
MEILI_HTTP_ADDR=http://localhost:7700 # Default Meilisearch URL
MEILI_MASTER_KEY=your_master_key # Optional: Default Meilisearch API key
Start the MCP server by running:
python -m meilisearch_mcp
Or with uvx:
uvx -n meilisearch-mcp
The MCP server automatically connects to the Meilisearch instance specified in your environment variables. You can view or update these connection settings at runtime using the provided tools:
get-connection-settings
to view current connection detailsupdate-connection-settings
to change the URL or API keyYou can create, list, and manage indices:
Use the create-index tool with an indexUid and optional primaryKey
Use the list-indexes tool to see all indices in your Meilisearch instance
Use get-index-metrics with an indexUid to see statistics about the index
Add and retrieve documents from your indices:
Use add-documents with indexUid and documents (JSON array) parameters
Use get-documents with indexUid and optional pagination parameters
The search functionality is flexible and powerful:
Use search with query and indexUid parameters
Use search with just the query parameter
Add filter, sort, limit, and offset parameters to refine your search
Configure how your search engine behaves:
Use get-settings with an indexUid parameter
Use update-settings with indexUid and the settings you want to change
Monitor the status of operations and system health:
Use get-tasks with optional filters to see the status of operations
Use health-check or get-health-status to verify your Meilisearch instance is running properly
If you encounter connection issues:
For task failures: