NPM-SEARCH(1)

πŸ’… NPM-SEARCH(1) β€” the manual page, bestie edition ✨

okay so you opened the manual page for NPM-SEARCH(1) and I'm gonna walk you through it like we're texting at 2am 🫢 this is the one about searching the registry for packages. buckle up.


πŸŽ€ NAME πŸŽ€

npm-search β€” literally just Search for packages πŸ’– that's the whole vibe.

✨ Synopsis ✨

npm search <search term> [<search term> ...]

aliases: find, s, se

so you can call it npm search, or you can be quirky and use find, s, or se β€” all four, same thing, no cap 😌

⚠️ Note: This command is unaware of workspaces. like, it simply does not know they exist. it's giving main character energy that refuses to acknowledge the group chat πŸ’€

🌸 DESCRIPTION 🌸

so npm search goes and searches the registry for packages that match your search terms. it does a linear, incremental, lexically-ordered search through package metadata for all files in the registry πŸ”₯ yes that's the exact wording, don't come for me, it's giving "we read the docs and we're repeating them faithfully."

if your terminal has color support, it'll highlight the matches in the results for you β€” so cute of it πŸ’… you can turn that off with the config item color if the rainbow is too much for you (it's never too much for me).

also!! you can use --searchopts and --searchexclude paired with more search terms to include and exclude further patterns. the main difference between --searchopts and the standard search terms is that the former does not highlight results in the output, and you can use them for more fine-grained filtering. and yeah you can put both of these in your config to change default search filtering behavior πŸ‘‘

search also lets you target maintainers in search results β€” just prefix their npm username with = 🫢 (iykyk)

and if a term starts with /, then it's interpreted as a regular expression and supports standard JavaScript RegExp syntax ⭐ in that case search will ignore a trailing /. (note: you must escape or quote many regular expression characters in most shells β€” fr fr, your shell will eat them alive otherwise 😭)


πŸ¦‹ CONFIGURATION πŸ¦‹

πŸ’œ json

  • Default: false
  • Type: Boolean

whether or not to output JSON data, rather than the normal output.

  • In npm pkg set it enables parsing set values with JSON.parse() before saving them to your package.json.

not supported by all npm commands πŸ™ˆ (so don't be surprised if some command ignores it, it's not being rude on purpose)

🌈 color

  • Default: true unless the NO_COLOR environ is set to something other than '0'
  • Type: "always" or Boolean

if false, never shows colors. if "always" then always shows colors. if true, then only prints color codes for tty file descriptors. slay ✨

πŸ“ parseable

  • Default: false
  • Type: Boolean

output parseable results from commands that write to standard output. for npm search, this will be tab-separated table format πŸ“‹ iconic honestly

🧚 description

  • Default: true
  • Type: Boolean

show the description in npm search πŸ’– (turn it off if you like your results mysterious)

⭐ searchlimit

  • Default: 20
  • Type: Number

number of items to limit search results to. will not apply at all to legacy searches πŸ‘€ noted and respected.

πŸ‘‘ searchopts

  • Default: ""
  • Type: String

space-separated options that are always passed to search.

πŸ’€ searchexclude

  • Default: ""
  • Type: String

space-separated options that limit the results from search. (the opposite bestie of the one above)

πŸ”₯ registry

the base URL of the npm registry.

🫢 prefer-online

  • Default: false
  • Type: Boolean

if true, staleness checks for cached data will be forced, making the CLI look for updates immediately even for fresh package data.

πŸ’œ prefer-offline

  • Default: false
  • Type: Boolean

if true, staleness checks for cached data will be bypassed, but missing data will be requested from the server. to force full offline mode, use --offline.

πŸŽ€ offline

  • Default: false
  • Type: Boolean

force offline mode: no network requests will be done during install. to allow the CLI to fill in missing cache data, see --prefer-offline.


🌟 SEE ALSO 🌟


okay that's the whole page, you're officially educated πŸ’… go forth and search. this was NPM@12.2.1, dated October 2026 (yes bestie, from the future 🌸), on the manual page NPM-SEARCH(1). mwah 🫢✨

πŸ“¦ where this page comes from