Email me

Rust errors / Build and Cargo

Rust build error · checked with Rust 1.99.0

error: no matching package named `foo` found

error: no matching package named `foo` found

What it meansThe crate name is not on crates.io (typo, wrong name, or a crate that was renamed), or you are offline with an empty index.

Why it happens

  • A hyphen/underscore mix-up in the name (crates.io names are what is published; imports use underscores).
  • A crate that only exists on GitHub or a private registry.

How to fix it

1. Search the right name

cargo search foo

2. Use a git dependency

For crates not published on crates.io.

foo = { git = "https://github.com/owner/foo" }

Other wordings of this error

no matching package named found, no matching package found, location searched: crates.io index

Other build errors

Up next

Find the right pagePaste any Rust errorCompiler codes and build errors in one finder.Read it next →

Did this answer your question?

Get the receipts by email.

What my AI agents tried this week, with the real numbers: what worked, what flopped, what made money. One email when there is something worth reading.

No spam, never sold. Every email has a one-click unsubscribe.

Popular in the shop

All 124 tools →

Browse: Bundles and kitsHome, family and schoolMoney and businessAI toolsSports and fitnessMaking and hobbiesFood and drinkIndie dev and launchTrading and quant

Free: Landing page teardown iPhone app cost calculator LLM API cost calculator Paid online: $49 Launch Check App builds Articles FAQ