thiserror
Hacker ApprovedRanked 3 of 8 Rust crates by recommenders
Rust crate that removes the boilerplate of defining strongly-typed error types for libraries, and stays transparent to downstream users. Common caveat: it makes forwarding errors too easy and macro expansions hard to debug.
Rust crate that removes the boilerplate of defining strongly-typed error types for libraries, and stays transparent to downstream users. Common caveat: it makes forwarding errors too easy and macro expansions hard to debug.
24 people gave an opinion
- recommend it
- 16
- criticize it
- 8
- approval share
- 67%
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: not recommended
- September 2026: not recommended
- October 2026: recommended
- November 2026: not recommended (month in progress)
Why it carries the badge
- 16 people recommend itNeeds 10 or more, met.
- 2 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
Removes boilerplate for error types
“makes said boilerplate a non-issue and allows you to properly propagate strongly-typed errors with context”
Comment from 4 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig” “thiserror and anyhow are std::error::Error with fewer steps.”
Comment from 25 May 2026 in “Migrating from Go to Rust” “Anyhow and thiserror are a cinch.”
Comment from 25 May 2026 in “Migrating from Go to Rust” Helps define standard library errors
“thiserror for libraries, helping you create the standard library error types”
Comment from 24 May 2026 in “Migrating from Go to Rust” “Crates like thiserror make it easy to define your own error types”
Comment from 27 Oct 2026 in “Four Months of Zig” “thiserror is an idiomatic approach these days”
Comment from 27 Oct 2026 in “Four Months of Zig” Pairs with anyhow 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” “thiserror¹ for libraries, anyhow² for applications”
Comment from 9 Jan 2026 in “An Honest Review of Go” “especially with crates like anyhow and thiserror”
Comment from 1 Nov 2025 on Hacker News Good ergonomics with precise errors
“Very very good ergonomics and completely transparent to downstream libraries.”
Comment from 31 May 2026 in “Custom Errors Are Non-Negotiable in My Rust Applications” “It's a nice compromise between being precise on your errors with your code”
Comment from 31 May 2026 in “Custom Errors Are Non-Negotiable in My Rust Applications” “I use thiserror a lot to help with my impls.”
Comment from 24 May 2026 in “Migrating from Go to Rust”
What people warn about
Each mark is one comment
Hard to debug macro expansions
“Now I'm debugging macro expansion errors and spending approximately the same amount of time”
Comment from 24 May 2026 in “Migrating from Go to Rust” “I spend ridiculous and unpredictable amounts of time debugging macro expansions”
Comment from 4 Dec 2025 in “Thoughts on Go vs. Rust vs. Zig” Encourages forwarding and public error enums
“thiserror actually encourages this sort of implementation leak”
Comment from 29 Dec 2025 in “Rust Errors Without Dependencies” “encourages a public error enum which to me is an anti-pattern”
Comment from 28 Dec 2025 in “Rust Errors Without Dependencies” “The thiserror crate makes it too easy to just foreward errors”
Comment from 4 Jan 2026 in “Stop Forwarding Errors, Start Designing Them” Tedious alongside other error crates
“Handling both types of these errors with `thiserror` can be tedious for little benefit.”
Comment from 25 May 2026 in “Migrating from Go to Rust” “Rust has three main error systems (io::Error, thiserror, and anyhow), which is a pain”
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) | 34 | 10 | 77% | 5 | — | Approved |
| Rayon | 18 | 2 | 90% | 10 | — | Approved |
| thiserrorThis page | 16 | 8 | 67% | 5 | — | Approved |
| rand crate | 9 | 3 | 75% | 4 | — | — |
| Facet (Rust reflection library) | 6 | 2 | 75% | 4 | — | — |
What people said
All 30 comments that mention it, newest first. Each links to the original comment.
“thiserror is an idiomatic approach these days”
“Crates like thiserror make it easy to define your own error types”
“It's a nice compromise between being precise on your errors with your code”
“Very very good ergonomics and completely transparent to downstream libraries.”
“Handling both types of these errors with `thiserror` can be tedious for little benefit.”
“Anyhow and thiserror are a cinch.”
“thiserror and anyhow are std::error::Error with fewer steps.”
“The example on the docs page is quite clear”
“Now I'm debugging macro expansion errors and spending approximately the same amount of time”
“I use thiserror a lot to help with my impls.”
“thiserror for libraries, helping you create the standard library error types”
“Rust has three main error systems (io::Error, thiserror, and anyhow), which is a pain”
“thiserror¹ for libraries, anyhow² for applications”
“The thiserror crate makes it too easy to just foreward errors”
“I feel like the Rust ecosystem of crates has naturally grown to handle these two ideas pretty well.”
“thiserror actually encourages this sort of implementation leak”
“libraries like thiserror make it easy and showcase it in their docs”
“If you're using a library like `thiserror`, then it's much less likely.”
“Rust should provide something like thiserror for libraries”
“I don't want upstream users of my libraries to incur this additional dependency”
“encourages a public error enum which to me is an anti-pattern”
“they all get abandoned sooner or later, and they brought very little to the table”
“I'd personally be on board with something like `thiserror` coming into `std`”
“I don't think `thiserror` and `anyhow` with their libraries vs applications distinction makes a lot of sense”
“And maybe not quite as standard, but thiserror if you don’t want a stringly-typed error?”
“Use thiserror to make error types in libraries, and anyhow in programs to handle them.”
“makes said boilerplate a non-issue and allows you to properly propagate strongly-typed errors with context”
“I haven't encountered problems with `thiserror` yet.”
“I spend ridiculous and unpredictable amounts of time debugging macro expansions”
“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.