cargo search


cargo-search - Search packages in


cargo search [OPTIONS] [QUERY…​]


This performs a textual search for crates on The matching crates will be displayed along with their description in TOML format suitable for copying into a Cargo.toml manifest.


Search Options

--limit LIMIT

Limit the number of results (default: 10, max: 100).

--index INDEX

The URL of the registry index to use.

--registry REGISTRY

Alternative registry to use.

This option is unstable and available only on the nightly channel and requires the -Z unstable-options flag to enable.

Display Options


Use verbose output. May be specified twice for "very verbose" output which includes extra output such as dependency warnings and build script output. May also be specified with the term.verbose config value.


No output printed to stdout.

--color WHEN

Control when colored output is used. Valid values:

  • auto (default): Automatically detect if color support is available on the terminal.

  • always: Always display colors.

  • never: Never display colors.

May also be specified with the term.color config value.

Common Options


Prints help information.


Unstable (nightly-only) flags to Cargo. Run cargo -Z help for details.


See the reference for details on environment variables that Cargo reads.

Exit Status


Cargo succeeded.


Cargo failed to complete.


  1. Search for a package from

    cargo search serde