Every premium and members-only resource for $9.99/month, as a no-commitment subscription. See the plans

PalateKit

Menu

Request a resource

Describe the resource you are missing in one sentence. We will email you when it is published.

0 / 280

Unlock PalateKit

Unlock everything

Plan

Paying means accepting our terms of sale.

Secure payment by Stripe. Receipts and invoices sent by email.

Welcome back

Sign in to install, download or save this resource. A free account is enough for free resources.

MongoDB query and index optimization v1.0.0

Use this resource to diagnose a slow MongoDB query and propose indexes

New

  • 521 downloads
  • 238 likes
  • 118 saves

Free

Install with the CLI

In a terminal, from the folder you want:

npx --yes palatekit@latest install mongodb-query-and-index-optimization

With no option, the skill goes to ~/.agents/skills/; add --agent claude-code (or codex, cursor…) to target an agent.

First time: connect the CLI with

npx --yes palatekit@latest login

The agent checks indexes and slow queries through the MongoDB MCP server, explains why a query is slow and proposes an index or a rewrite. It only steps in for performance requests, not for routine query writing.

Mostly picked by

Updated November 2, 2026

Card for the “MongoDB query and index optimization” skill

Details

Generates with
Your agent's model
Licence
Apache-2.0

Similar resources

View all

What you get

  • references/core-indexing-principles.md: indexing principles
  • references/aggregation-optimization.md: aggregation pipeline optimization
  • references/antipattern-examples.md: anti-pattern examples and their fixes

Good fit for

  • A query takes several seconds on a large collection
  • You want the list of slow queries on your cluster

Not for

    Tags

    • mongodb
    • index
    • slow queries
    • aggregation

    About

    You say

    “Why is this query on the orders collection slow, and which index would make it fast?”

    Card for the “MongoDB query and index optimization” skill

    Skill published by mongodb under the Apache-2.0 license, delivered in its original version.

    Show more

    How to use it

    1. Install the skill in your agent's skills folder
    2. Ask your agent to diagnose a slow MongoDB query and propose indexes
    3. Review and adjust the result

    Content preview

    Files

    • LICENSE11.3 KB
    • NOTICE-PALATEKIT.md0.5 KB
    • references/aggregation-optimization.md6.8 KB
    • references/antipattern-examples.md2.5 KB
    • references/core-indexing-principles.md4.3 KB
    • references/update-query-examples.md1.2 KB
    • SKILL.md10.2 KB

    Origin and licence

    Listed unmodified

    Author
    mongodb
    Source
    github.com/mongodb/agent-skills/tree/155bb9c4b42a9a3e019f47be0669de0e4547d1ea/skills/mongodb-query-optimizer
    Licence
    Apache-2.0

    Notice

    « mongodb-query-optimizer » (mongodb, Apache-2.0) livré dans sa version d'origine : fiche en français et en anglais par PalateKit.

    User reviews

    –

    No ratings yet

    Loading reviews…

    Delete your review?

    Your rating and comment will be removed from the page.