anyhow (Rust crate)
Hacker ApprovedThe most recommended of 8 Rust crates
Recommended for easy error propagation and added context in Rust application code. Critics note it should not appear in library public APIs.
Recommended for easy error propagation and added context in Rust application code. Critics note it should not appear in library public APIs.
44 people gave an opinion
- recommend it
- 34
- criticize it
- 10
- approval share
- 77%
Recommended in 5 of 13 months
- November 2025: recommended
- December 2025: recommended
- January 2026: recommended
- February 2026: not recommended
- March 2026: not recommended
- April 2026: not recommended
- May 2026: recommended
- June 2026: not recommended
- July 2026: not recommended
- August 2026: recommended
- September 2026: not recommended
- October 2026: not recommended
- November 2026: not recommended (month in progress)
Why it carries the badge
- 34 people recommend itNeeds 10 or more, met.
- 3.4 recommenders for every criticNeeds 2 to 1 or better, met.
- Recommended in 5 of 13 monthsNeeds 4 or more, met.
The same three rules apply to every product, and the badge can’t be bought. How the badge works
What people say about it
The reasons people give, with the number of comments that give each one. Open a reason to read what they said.
Why people recommend it
Each mark is one comment
Standard pick for applications
“Use thiserror to make error types in libraries, and anyhow in programs to handle them.”
Comment from 4 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig” “anyhow for applications, thiserror for libraries.”
Comment from 30 Dec 2025 in “The Second Great Error Model Convergence” “something like anyhow for applications”
Comment from 28 Dec 2025 in “Rust Errors Without Dependencies” - Comment from 4 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig”
Adds error context conveniently
“using eyre or anyhow or other error context libraries build convenient error context backtraces without needing to format things oneself”
Comment from 5 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig” “you can use things like anyhow or error_context to add context before returning”
Comment from 4 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig” “just use anyhow with .context”
Comment from 5 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig” - Comment from 24 May 2026 in “Migrating from Go to Rust”
Easy error propagation up stacks
“I've never had a problem using anyhow to pass errors up the call stack in any project I've used it in.”
Comment from 25 May 2026 in “Migrating from Go to Rust” “The pros for using anyhow are big: Easily stack errors together”
Comment from 28 Dec 2025 in “Rust Errors Without Dependencies” “anyhow seems useful in the very top layers where you basically just want bubble the useful errors modeled elsewhere”
Comment from 28 Dec 2025 in “Rust Errors Without Dependencies” Fail fast without panicking
“goes a long way to being able to fail fast and return an Err rather then panicking”
Comment from 19 Nov 2025 in “Cloudflare outage on November 18, 2025 post mortem” “it’s so much less friction, and much better than just doing panic”
Comment from 28 Dec 2025 in “Rust Errors Without Dependencies”
What people warn about
Each mark is one comment
Not for library public APIs
“you are not supposed to expose errors from a library with anyhow, they are only for application/top level code”
Comment from 26 May 2026 in “Migrating from Go to Rust” “if a library ever exposes that, then that's just the author being lazy and not doing errors correctly”
Comment from 25 May 2026 in “Migrating from Go to Rust” “this gets things done, but I'm told not to expose these errors in my public API”
Comment from 4 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig” - Comment from 25 May 2026 in “Migrating from Go to Rust”
Still verbose, boilerplate remains
“Even with anyhow there is a lot of boilerplate it seems to me dealing with crates that don't use it.”
Comment from 22 Jan 2026 in “Nanolang: A tiny experimental language designed to be targeted by coding LLMs” “Anyhow mostly works but this is approximately as verbose as the Go error handling”
Comment from 24 May 2026 in “Migrating from Go to Rust”
Other Rust crates people recommend
The four most recommended other Rust crates, with the same counts for each, so you can compare like for like. The tick on each bar marks the 2 to 1 line the badge needs.
| Product | Recommend | Criticize | Approval | Months | Owned | Badge |
|---|---|---|---|---|---|---|
| anyhow (Rust crate)This page | 34 | 10 | 77% | 5 | — | Approved |
| Rayon | 18 | 2 | 90% | 10 | — | Approved |
| thiserror | 16 | 8 | 67% | 5 | — | Approved |
| rand crate | 9 | 3 | 75% | 4 | — | — |
| Facet (Rust reflection library) | 6 | 2 | 75% | 4 | — | — |
What people said
40 of the 46 comments that mention it, newest first. Each links to the original comment.
“Rust's anyhow crate was able to square this circle by adding a blanket trait impl for Context”
“you are not supposed to expose errors from a library with anyhow, they are only for application/top level code”
“I've never had a problem using anyhow to pass errors up the call stack in any project I've used it in.”
“if a library ever exposes that, then that's just the author being lazy and not doing errors correctly”
“Anyhow and thiserror are a cinch.”
“If a crate exposes `anyhow::Error`, that's a lazy choice and bad API design”
“thiserror and anyhow are std::error::Error with fewer steps.”
“Anyhow mostly works but this is approximately as verbose as the Go error handling”
“Anyhow is perhaps the closest one to another paradigm because it allows you to discard typed information in favor of just the string messages”
“I use anyhow for this, so I should also add "add context to an error when I fall" to the list of things I do.”
“Or just go with Anyhow until you find a need for something else.”
“Rust has three main error systems (io::Error, thiserror, and anyhow), which is a pain”
“anyhow and syn are literally from a core Rust dev”
“Even with anyhow there is a lot of boilerplate it seems to me dealing with crates that don't use it.”
“exn can use anyhow::Error as its inner Error”
“Rust already has a head start compared to most other languages with Result, expect and anyhow”
“If one skips that part and opts for anyhow because it's too much work, that's really a user problem.”
“anyhow for applications, thiserror for libraries.”
“most of them are favorable (or not unfavorable) to anyhow”
“I usually use `anyhow` to do that for me”
“something like anyhow for applications”
“it’s so much less friction, and much better than just doing panic”
“anyhow seems useful in the very top layers where you basically just want bubble the useful errors modeled elsewhere”
“either a third party dependency (anyhow) that mimics Go's errors stdlib package”
“they all get abandoned sooner or later, and they brought very little to the table”
“The pros for using anyhow are big: Easily stack errors together”
“just use anyhow with .context”
“using eyre or anyhow or other error context libraries build convenient error context backtraces without needing to format things oneself”
“I believe `anyhow` can mostly do the same.”
“the standard convention if you just want a stringly-typed error like Go is anyhow?”
“Use thiserror to make error types in libraries, and anyhow in programs to handle them.”
“you can use things like anyhow or error_context to add context before returning”
“Just anyhow macro wrap your errors and just log them out.”
“this gets things done, but I'm told not to expose these errors in my public API”
“goes a long way to being able to fail fast and return an Err rather then panicking”
“Anyhow is a great thing to get you started.”
“It keeps the size of Result down by limiting the 'E' to be a pointer.”
“anyhow::Error (or similar) seems poised to become idiomatic in Rust, which AFAIU always allocates”
“No matter what error we put into an anyhow::Error, the stack size is 8 B.”
“especially with crates like anyhow and thiserror”
Counts come from 1,795,640 Hacker News comments, November 2025 to November 2026. How we count. Report a mistake.