Npgsql 10.0.3

Npgsql is the open source .NET data provider for PostgreSQL. It allows you to connect and interact with PostgreSQL server using .NET.

Quickstart

Here's a basic code snippet to get you started:

var connString = "Host=myserver;Username=mylogin;Password=mypass;Database=mydatabase";

await using var conn = new NpgsqlConnection(connString);
await conn.OpenAsync();

// Insert some data
await using (var cmd = new NpgsqlCommand("INSERT INTO data (some_field) VALUES (@p)", conn))
{
    cmd.Parameters.AddWithValue("p", "Hello world");
    await cmd.ExecuteNonQueryAsync();
}

// Retrieve all rows
await using (var cmd = new NpgsqlCommand("SELECT some_field FROM data", conn))
await using (var reader = await cmd.ExecuteReaderAsync())
{
while (await reader.ReadAsync())
    Console.WriteLine(reader.GetString(0));
}

Key features

  • High-performance PostgreSQL driver. Regularly figures in the top contenders on the TechEmpower Web Framework Benchmarks.
  • Full support of most PostgreSQL types, including advanced ones such as arrays, enums, ranges, multiranges, composites, JSON, PostGIS and others.
  • Highly-efficient bulk import/export API.
  • Failover, load balancing and general multi-host support.
  • Great integration with Entity Framework Core via Npgsql.EntityFrameworkCore.PostgreSQL.

For the full documentation, please visit the Npgsql website.

Showing the top 20 packages that depend on Npgsql.

Packages Downloads
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
48
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
42
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
41
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
40
Npgsql.EntityFrameworkCore.PostgreSQL
Npgsql.EntityFrameworkCore.PostgreSQL
39
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
39
EFCore.BulkExtensions.PostgreSql
EntityFramework .Net EFCore EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on PostgreSQL
38
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
38
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
37
AspNetCore.HealthChecks.NpgSql
HealthChecks.NpgSql is a health check for Postgress Sql.
37
Npgsql.EntityFrameworkCore.PostgreSQL
PostgreSQL/Npgsql provider for Entity Framework Core.
36

Version Downloads Last updated
10.0.3 23 05/29/2026
10.0.2 41 03/13/2026
10.0.1 55 12/20/2025
10.0.0 37 12/10/2025
10.0.0-rc.1 45 12/11/2025
9.0.5 34 03/13/2026
9.0.4 39 12/14/2025
9.0.3 32 12/13/2025
9.0.2 33 12/13/2025
9.0.1 41 12/24/2025
8.0.9 39 03/13/2026
8.0.8 29 01/08/2026
8.0.7 40 12/11/2025
8.0.6 38 12/15/2025
8.0.5 39 01/05/2026
8.0.4 35 12/15/2025
8.0.3 43 12/14/2025
8.0.2 48 12/14/2025
8.0.1 34 12/23/2025
8.0.0 43 12/14/2025
8.0.0-rc.2 37 12/16/2025
8.0.0-preview.4 46 12/15/2025
8.0.0-preview.3 32 12/15/2025
8.0.0-preview.2 23 01/05/2026
8.0.0-preview.1 35 12/20/2025
7.0.10 42 12/12/2025
7.0.9 28 01/01/2026
7.0.8 57 12/11/2025
7.0.7 32 12/13/2025
7.0.6 40 12/28/2025
7.0.4 28 12/12/2025
7.0.2 32 12/21/2025
7.0.1 30 12/09/2025
7.0.0 39 12/19/2025
7.0.0-rc.2 34 12/14/2025
7.0.0-rc.1 43 12/12/2025
7.0.0-preview.7 39 12/09/2025
7.0.0-preview.6 45 12/12/2025
7.0.0-preview.5 36 12/31/2025
7.0.0-preview.4 31 12/22/2025
7.0.0-preview.3 35 01/05/2026
7.0.0-preview.2 33 12/24/2025
7.0.0-preview.1 39 12/15/2025
6.0.13 29 12/13/2025
6.0.12 45 12/20/2025
6.0.11 33 12/15/2025
6.0.10 42 12/20/2025
6.0.9 42 12/11/2025
6.0.8 36 12/15/2025
6.0.7 30 01/06/2026
6.0.6 47 12/10/2025
6.0.5 42 01/05/2026
6.0.4 36 12/12/2025
6.0.3 37 12/18/2025
6.0.2 32 12/10/2025
6.0.1 39 01/11/2026
6.0.0 35 12/13/2025
6.0.0-rc.2 32 12/09/2025
6.0.0-rc.1 32 12/18/2025
6.0.0-preview7 37 12/12/2025
6.0.0-preview6 41 12/23/2025
6.0.0-preview5 46 12/23/2025
6.0.0-preview4 33 12/23/2025
6.0.0-preview3 36 12/25/2025
6.0.0-preview2 35 12/13/2025
5.0.18 43 12/11/2025
5.0.17 33 12/20/2025
5.0.16 30 12/20/2025
5.0.15 29 12/15/2025
5.0.14 38 12/20/2025
5.0.13 31 12/14/2025
5.0.12 38 12/10/2025
5.0.11 37 12/13/2025
5.0.10 25 12/20/2025
5.0.7 36 01/07/2026
5.0.5 39 12/13/2025
5.0.4 26 12/23/2025
5.0.3 33 12/11/2025
5.0.2 31 12/13/2025
5.0.1.1 41 12/15/2025
5.0.0 42 12/29/2025
4.1.14 42 12/15/2025
4.1.13 39 12/14/2025
4.1.12 31 12/11/2025
4.1.11 43 01/01/2026
4.1.10 32 12/10/2025
4.1.9 45 12/11/2025
4.1.8 40 12/23/2025
4.1.7 43 12/24/2025
4.1.6 36 12/22/2025
4.1.5 37 12/16/2025
4.1.4 39 12/13/2025
4.1.3.1 29 01/01/2026
4.1.3 37 12/09/2025
4.1.2 30 12/23/2025
4.1.1 35 12/10/2025
4.1.0 46 12/12/2025
4.0.17 52 12/13/2025
4.0.16 40 12/16/2025
4.0.14 39 12/20/2025
4.0.13 42 12/20/2025
4.0.12 38 12/20/2025
4.0.11 42 12/13/2025
4.0.10 29 12/20/2025
4.0.9 32 12/23/2025
4.0.8 37 12/13/2025
4.0.7 47 12/22/2025
4.0.6 45 02/05/2026
4.0.5 41 12/20/2025
4.0.4 44 12/12/2025
4.0.3 30 12/23/2025
4.0.2 50 12/24/2025
4.0.1 28 12/27/2025
4.0.0 38 12/17/2025
4.0.0-rc1 43 12/15/2025
4.0.0-preview2 31 01/01/2026
4.0.0-preview1 32 12/23/2025
3.2.7 40 12/11/2025
3.2.6 35 01/09/2026
3.2.5 34 12/20/2025
3.2.4.1 29 01/01/2026
3.2.4 34 12/14/2025
3.2.3 40 12/16/2025
3.2.2 40 01/01/2026
3.2.1 36 12/24/2025
3.2.0 36 01/09/2026
3.1.10 36 12/20/2025
3.1.9 36 12/24/2025
3.1.8 33 12/13/2025
3.1.7 33 12/15/2025
3.1.6 30 12/10/2025
3.1.5 42 01/01/2026
3.1.4 37 12/16/2025
3.1.3 29 12/14/2025
3.1.2 22 12/14/2025
3.1.1 21 01/06/2026
3.1.0 37 12/12/2025
3.0.8 34 12/16/2025
3.0.7 30 01/01/2026
3.0.6 39 12/14/2025
3.0.5 29 12/19/2025
3.0.4 25 01/01/2026
3.0.3 33 12/11/2025
3.0.2 30 12/24/2025
3.0.1 31 12/17/2025
3.0.0 22 01/11/2026
2.2.7 49 12/31/2025
2.2.6 32 12/11/2025
2.2.5 39 12/24/2025
2.2.4.3 41 01/04/2026
2.2.4.1 39 12/30/2025
2.2.3 41 12/12/2025
2.2.2 36 12/20/2025
2.2.1 36 12/12/2025
2.2.0 41 12/12/2025
2.1.3 39 12/23/2025
2.1.2 37 12/24/2025
2.1.1 34 12/18/2025
2.1.0 33 12/14/2025
2.0.14.3 41 12/13/2025
2.0.12.1 32 12/22/2025
2.0.11 35 12/20/2025