Why did we make Diesel?

Preventing Runtime Errors

We don’t want to waste time tracking down runtime errors. We achieve this by having Diesel eliminate the possibility of incorrect database interactions at compile time.

Built for Performance

Diesel offers a high level query builder and lets you think about your problems in Rust, not SQL. Our focus on zero-cost abstractions allows Diesel to run your query and load your data even faster than C.

Productive and Extensible

Unlike Active Record and other ORMs, Diesel is designed to be abstracted over. Diesel enables you to write reusable code and think in terms of your problem domain and not SQL.

See some examples

Simple queries are a complete breeze. Loading all users from a database:

Executed SQL

Loading all the posts for a user:

Diesel’s codegen can generate several ways to update a row, letting you encapsulate your logic in the way that makes sense for your app.

The community has made some utilities to help make diesel even easier to work with!

dsync License: MIT OR Apache-2.0

Generate rust structs & query functions from diesel schema files.

Something missing? Submit an issue here.