Docs Menu
Docs Home
/ /

$searchMeta (aggregation stage)

searchMeta returns different types of metadata result documents for MongoDB Search queries on the field or fields in an Atlas collection. The fields must be covered by a MongoDB Search index. See:

  • Index Definitions to learn more about creating and managing MongoDB Search indexes.

  • MongoDB Search Aggregation Pipeline Stages to learn more about the $searchMeta pipeline stage syntax, usage, and results.

Important

The $searchMeta aggregation pipeline stage is available for collections hosted on:

  • MongoDB Atlas.

  • MongoDB Enterprise deployments running version 8.2 or later with the Kubernetes Operator.

  • MongoDB Community deployments running version 8.2 or later.

To learn more, see MongoDB Search.

Back

$search