Context7 MCP

Search for libraries

Search locally indexed libraries by name
1 min read
gethttps://your-instance.example.com/api/v2/libs/search
Request example
Response
gethttps://your-instance.example.com/api/v2/libs/search

Query parameters

libraryNamestringrequired#
Library name to search for (e.g., react, nextjs)

Length: 1–500

querystringrequired#
User's original question or task - used for relevance ranking

Length: 1–500

Responses

application/json
Search results ranked by relevance
resultsobject[]required#
Matching libraries ranked by relevance
Show child attributes
idstring#
Library ID to pass to GET /v2/context
titlestring#
Display name
descriptionstring#
Short description
totalSnippetsinteger#
Number of indexed snippets
sourcestring#
Where the library was indexed from
trustScoreinteger#
Source reputation score (0–10)