Meilisearch
Lightning-fast hybrid search engine with AI-powered semantic and full-text retrieval for modern applications.
Meilisearch is an open-source search engine written in Rust that delivers hybrid search — combining full-text and semantic vector retrieval — with typo tolerance, faceting, geosearch, and conversational AI capabilities, all through a clean RESTful API. It is designed for developers who need fast, relevant, and highly customizable search without the overhead of managing multiple independent search systems.
The engine returns results in under 50 milliseconds and supports SDKs for JavaScript, Python, Go, Ruby, Java, .NET, PHP, and more. Meilisearch can be self-hosted on any infrastructure or deployed via Meilisearch Cloud, with built-in support for multi-tenancy, horizontal sharding, replication, and vector storage using a proprietary HNSW implementation called hannoy.
Meilisearch integrates natively with LangChain and the Model Context Protocol (MCP), making it a natural fit for retrieval-augmented generation (RAG) workflows. Enterprise Edition features — including replicated sharding and certain advanced capabilities — are gated behind a commercial license, while the Community Edition is fully MIT-licensed and suitable for most production use cases.
The project has been actively developed since 2018, now at version 1.47, with a release cadence of roughly one new version per week and over 58,000 GitHub stars. Its modular Rust workspace, embedded LMDB-based storage, and comprehensive integration test suite make it one of the most production-ready self-hostable search engines available.
What You Get
- Hybrid search - Combines full-text keyword matching with semantic vector similarity to surface the most relevant results even when queries don’t exactly match document text.
- Search-as-you-type - Returns ranked results in under 50 milliseconds per query, enabling a fluid, real-time search experience without additional infrastructure.
- Typo tolerance - Automatically handles misspellings and inexact queries without requiring developers to configure fuzzy matching rules or edit distance thresholds.
- Faceted search and filtering - Build rich filter UIs with categorical facets, numeric range filters, and multi-select navigation for e-commerce, media, and enterprise apps.
- Geosearch - Filter and rank search results by geographic proximity using latitude/longitude coordinates, enabling ‘near me’ and radius-based search patterns.
- Conversational search - Allow users to ask natural language questions and receive AI-generated answers grounded in your indexed content via the chat completion API.
- Multi-tenancy with tenant tokens - Isolate and personalize search results per user or organization within a single instance using signed JWT-based tenant tokens.
- Vector storage and HNSW retrieval - Store and query vector embeddings using an in-house HNSW index (hannoy) for semantic similarity and RAG without external vector databases.
- Personalized search - Tailor result ranking to individual users based on behavioral signals and preferences without requiring custom ranking rule overrides.
- Document relations - Link and enrich documents across indexes to surface related content, such as product reviews alongside product listings, in a single query.
- Horizontal sharding and replication - Distribute indexes across multiple nodes with the Enterprise Edition’s replicated sharding for high availability and throughput.
- LangChain and MCP integration - Connect Meilisearch directly to AI pipelines using its native LangChain retriever and Model Context Protocol server for RAG applications.
Common Use Cases
- E-commerce product search - An online retailer uses Meilisearch to offer typo-tolerant, faceted search with price filters and category navigation across hundreds of thousands of SKUs with sub-50ms latency.
- Media and streaming discovery - A video platform deploys hybrid search so users can find content by title keywords or semantic similarity to plot descriptions without needing to know exact terms.
- Multi-tenant SaaS CRM - A B2B SaaS product uses tenant tokens to enforce per-organization data isolation while delivering personalized search over contacts, companies, and deals.
- Location-aware application - A travel booking app leverages geosearch to return hotels, restaurants, or experiences within a configurable radius of the user’s coordinates.
- RAG-powered knowledge base - A support team deploys Meilisearch with LangChain to retrieve relevant documentation passages and feed them to an LLM for grounded, accurate answers.
- Federated multi-source search - A content aggregator runs federated multi-index queries to merge results from separate news, blog, and document indexes into a unified, relevance-ranked response.
Under The Hood
Architecture Meilisearch is structured as a Rust workspace with well-separated crates: the HTTP server and routing layer (actix-web), the search engine core (milli), an asynchronous task scheduler (index-scheduler), an authentication controller, shared type definitions, and specialized utility crates. The design enforces a clean separation between HTTP concerns and business logic through an extraction middleware layer, while the core indexing and ranking algorithms remain isolated in milli for independent testability. Task execution uses a background scheduler thread with backpressure-aware batch processing that wakes on new task registration or completion. Enterprise Edition capabilities — such as replicated sharding — are cleanly gated at the routing layer, with separate community and enterprise route handler files, ensuring no code paths are mixed.
Tech Stack The entire server is implemented in Rust using actix-web as the HTTP framework with mimalloc as the global allocator for reduced allocation overhead. The search engine uses heed (LMDB Rust bindings) as the embedded ACID-compliant key-value store, eliminating any external database dependency. Vector search is powered by hannoy, an in-house HNSW implementation replacing the earlier arroy-based store, alongside cellulite for supplementary vector operations. Multilingual tokenization is handled by charabia with optimized support for CJK scripts and Latin alphabets. The project ships as a statically linked binary in a minimal Alpine Docker image, making deployment simple and the container footprint small.
Code Quality The codebase contains an extensive test suite with over 480 test functions across integration, snapshot, and unit tests covering search relevance, settings management, authentication, vector features, facets, and upgrade paths. The meili-snap crate provides snapshot testing for API responses, ensuring regression-free evolution across releases. Error handling is explicit and typed throughout, using Rust’s Result and Option primitives with detailed custom error codes surfaced to API consumers via the deserr crate, which unifies deserialization of JSON, query parameters, and headers with automatic structured error generation. Clippy and rustfmt are enforced in CI, and the project maintains separate profiling, benchmarking, and testing documentation.
What Makes It Unique Meilisearch’s primary differentiation is integrating hybrid search — combining BM25-style full-text ranking with semantic HNSW vector retrieval — as a first-class primitive rather than a bolt-on. The proprietary hannoy HNSW implementation is tuned specifically for Meilisearch’s indexing and query patterns, with a recent migration from legacy arroy improving indexing throughput by hundreds of seconds on large datasets. The deserr crate’s approach to unified, structured request validation with automatic error code generation is uncommon in search engines. Federated multi-index search with coherent relevance merging, fine-grained API key permission scoping at the route layer, and native MCP and LangChain integration position Meilisearch as purpose-built for AI-native application development.
Self-Hosting
Meilisearch is dual-licensed. The Community Edition is released under the MIT license, which grants broad freedoms: you can use it commercially, modify the source, redistribute it, and self-host it in production with no royalties or restrictions. Enterprise Edition (EE) features — such as replicated sharding and certain advanced networking capabilities — are licensed under the Business Source License 1.1 (BUSL-1.1). The BUSL restricts production use of those specific EE-marked files to holders of a commercial agreement with Meilisearch; non-production use (development, testing, evaluation) is permitted. EE code automatically converts to MIT four years after each version’s publication date, so the distinction is time-limited rather than permanent.
Operationally, self-hosting Meilisearch is straightforward for the Community Edition: it ships as a single statically linked binary with no external database required, since it uses embedded LMDB storage (via heed). You can run it with Docker, directly on a Linux server, or on any platform with a Rust-capable build chain. Operational responsibilities include managing disk space for the LMDB data files, handling process restarts and crash recovery, scheduling snapshots or dumps for backup, and performing binary upgrades (which may include in-place dumpless upgrades). For high-traffic deployments, you are responsible for scaling, monitoring, and ensuring uptime — none of which is managed for you in the self-hosted path.
The managed Meilisearch Cloud offering adds analytics dashboards, automatic upgrades, multi-region availability, SLA-backed uptime, managed backups, and access to Enterprise Edition features including replicated sharding. For teams that need guaranteed uptime, compliance features, or are not resourced to manage infrastructure, the cloud tier closes a real gap that the self-hosted Community Edition does not cover. Meilisearch’s support model also differs: community users rely on GitHub issues and Discord, while cloud and enterprise customers receive dedicated support channels and SLAs.