Overview
Dapper was developed at Stack Overflow in 2011 and is now maintained in the DapperLib organisation, with Marc Gravell's account the most active contributor. It adds extension methods such as Query<T>, QuerySingle<T> and Execute to any DbConnection, binds parameters from anonymous objects, dictionaries or DynamicParameters, and maps rows to your classes. Multi-mapping handles joins into several objects, and QueryMultiple reads several result sets in one round trip.
Because it does not translate a query language, track changes or manage identity, Dapper stays fast and predictable; the Learn Dapper site describes it as a micro-ORM focused on object mapping. Optional packages add CRUD helpers (Dapper.Rainbow) and a composable SQL builder (Dapper.SqlBuilder).
Many teams combine Dapper with EF Core: EF Core for migrations and writes, Dapper for read-heavy queries. For bulk inserts and updates, ZZZ Projects sells Dapper Plus under a perpetual licence. Dapper has no configuration step and no model to register: you add the NuGet package, open a connection with any ADO.NET provider and call the extension methods. That makes it easy to adopt in an existing codebase one query at a time.
Pricing and plans
| Plan | Price | What you get |
|---|---|---|
| Dapper | $0 | Open source |
| Dapper Plus (third party) | $1,399 one-time | ZZZ Projects bulk-operations library; perpetual licence with 1 year of updates; figure shown for the default selection on its configurator |
What it does
- Query and Execute
- Extension methods on DbConnection for multi-row, single-row and scalar queries and commands, sync or async.
- Parameter binding
- Pass POCOs, anonymous types, dictionaries or DynamicParameters; values are parameterised.
- Multi-mapping
- Split one joined row into several related objects.
- Multiple result sets
- QueryMultiple reads several result sets from one command.
- Add-on packages
- Dapper.Rainbow CRUD helpers and Dapper.SqlBuilder for composing SQL.
Strengths and limitations
Strengths
- Very low overhead compared with full ORMs
- Works with any ADO.NET provider
- Tiny API that takes minutes to learn
- Proven at Stack Overflow scale
Limitations
- No change tracking, SQL generation, lazy loading or migrations
- You write and maintain all SQL by hand, per database dialect
- SQL strings are not checked at compile time
- Bulk operations need the paid third-party Dapper Plus or your own code
Who it suits
Good for
- Read-heavy .NET APIs
- Teams with strong SQL skills or existing stored procedures
- Pairing with EF Core for performance-sensitive queries
Look elsewhere if
- Teams that want migrations and LINQ (EF Core)
- Apps with complex object graphs to persist
Alternatives to Dapper
| Tool | From | Free option | Stages |
|---|---|---|---|
| Entity Framework Core .NET ORM | — | ||
| Eloquent ORM Active Record ORM for Laravel | — | ||
| Active Record (Rails) Active Record ORM for Ruby on Rails | — | ||
| SQLAlchemy Python SQL toolkit and ORM | — | ||
| Hibernate ORM Java ORM and Jakarta Persistence implementation | — | ||
| Diesel Compile-time checked Rust ORM and query builder | — |
Questions
Is Dapper free?
Yes, Dapper is open source. Dapper Plus, a separate bulk-operations library from ZZZ Projects, is paid.
Is Dapper an ORM?
It is a micro-ORM: it maps query results to objects but does not generate SQL, track changes or run migrations.
Can I use Dapper with EF Core?
Yes. Both work on ADO.NET connections, and many apps use EF Core for writes and migrations and Dapper for fast reads.
Sources read for this page