Type to search.

Full-text search in Elasticsearch

Serverless

Elastic Cloud Serverless projects are autoscaled environments, fully managed by Elastic and available on Elastic Cloud.

Availability

  • Generally available

    This functionality is generally available and ready for production usage.

Serverless interfaces and procedures might differ from classic Elastic Stack deployments.

Stack

The Elastic Stack includes Elastic's core products such as Elasticsearch, Kibana, Logstash, and Beats.

Availability

  • Generally available

    This functionality is generally available and ready for production usage.

Unless stated otherwise on the page, this functionality is available when your Elastic Stack is deployed on Elastic Cloud Hosted, Elastic Cloud Enterprise, Elastic Cloud on Kubernetes, and self-managed environments.

This documentation corresponds to the latest patch available for each minor version. If you're not using the latest patch, check the release notes for changes.

Tip

If you'd prefer to start with a hands-on example, refer to our full-text search tutorial.

Full-text search, also known as lexical search, is a technique for fast, efficient searching through text fields in documents. Documents and search queries are transformed to enable returning relevant results instead of simply exact term matches. Fields of type text are analyzed and indexed for full-text search.

Built on decades of information retrieval research, full-text search delivers reliable results that scale predictably as your data grows. Because it runs efficiently on CPUs, Elasticsearch's full-text search requires minimal computational resources compared to GPU-intensive vector operations.

You can combine full-text search with semantic search using vectors to build modern hybrid search-powered applications. While vector search may require additional GPU resources, the full-text component remains cost-effective by leveraging existing CPU infrastructure.

For a high-level overview of how full-text search works, refer to How full-text search works.

For a hands-on introduction to full-text search, refer to the full-text search tutorial.

Here are some resources to help you learn more about full-text search with Elasticsearch.

Core concepts

Learn about the core components of full-text search:

Elasticsearch query languages

Learn how to build full-text search queries using Elasticsearch's query languages:

Advanced topics

For a technical deep dive into Elasticsearch's BM25 implementation read this blog post: The BM25 Algorithm and its Variables.

To learn how to optimize the relevance of your search results, refer to Search relevance optimizations.