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.DependencyInjection
Package Description
60
Npgsql.DependencyInjection
Package Description
59
Npgsql.DependencyInjection
Package Description
58
Npgsql.DependencyInjection
Package Description
57
Npgsql.DependencyInjection
Package Description
56
Npgsql.DependencyInjection
Package Description
55

Version Downloads Last updated
10.0.3 27 05/28/2026
10.0.2 38 03/13/2026
10.0.1 49 12/20/2025
10.0.0 47 11/24/2025
10.0.0-rc.1 57 10/10/2025
9.0.5 39 03/13/2026
9.0.4 61 10/10/2025
9.0.3 65 09/02/2025
9.0.2 57 09/05/2025
9.0.1 58 09/05/2025
8.0.9 35 03/13/2026
8.0.8 58 10/10/2025
8.0.7 57 09/05/2025
8.0.6 58 09/05/2025
8.0.5 59 09/05/2025
8.0.4 58 09/05/2025
8.0.3 62 09/05/2025
8.0.2 58 09/05/2025
8.0.1 59 09/05/2025
8.0.0 61 09/05/2025
8.0.0-rc.2 63 09/05/2025
8.0.0-preview.4 60 09/05/2025
8.0.0-preview.3 55 09/05/2025
8.0.0-preview.2 58 09/05/2025
8.0.0-preview.1 55 09/05/2025
7.0.10 59 09/05/2025
7.0.9 62 09/05/2025
7.0.8 59 09/05/2025
7.0.7 58 09/05/2025
7.0.6 61 09/05/2025
7.0.4 60 09/05/2025
7.0.2 58 09/05/2025
7.0.1 62 09/05/2025
7.0.0 59 09/05/2025
7.0.0-rc.2 57 09/05/2025
7.0.0-rc.1 57 09/05/2025
7.0.0-preview.7 58 09/05/2025
7.0.0-preview.6 59 09/05/2025
7.0.0-preview.5 60 09/05/2025
7.0.0-preview.4 58 09/05/2025
7.0.0-preview.3 57 09/05/2025
7.0.0-preview.2 58 09/05/2025
7.0.0-preview.1 59 09/05/2025
6.0.13 58 09/05/2025
6.0.12 59 09/05/2025
6.0.11 56 09/05/2025
6.0.10 57 09/05/2025
6.0.9 59 09/05/2025
6.0.8 57 09/05/2025
6.0.7 60 09/05/2025
6.0.6 59 09/05/2025
6.0.5 58 09/05/2025
6.0.4 56 09/05/2025
6.0.3 61 09/05/2025
6.0.2 60 09/05/2025
6.0.1 58 09/05/2025
6.0.0 55 09/05/2025
6.0.0-rc.2 63 09/05/2025
6.0.0-rc.1 60 09/05/2025
6.0.0-preview7 60 09/05/2025
6.0.0-preview6 58 09/05/2025
6.0.0-preview5 56 09/05/2025
6.0.0-preview4 61 09/05/2025
6.0.0-preview3 59 09/05/2025
6.0.0-preview2 62 09/05/2025
5.0.18 62 09/05/2025
5.0.17 66 09/05/2025
5.0.16 61 09/05/2025
5.0.15 58 09/05/2025
5.0.14 63 09/05/2025
5.0.13 61 09/05/2025
5.0.12 60 09/05/2025
5.0.11 56 09/05/2025
5.0.10 64 09/05/2025
5.0.7 57 09/05/2025
5.0.5 57 09/05/2025
5.0.4 56 09/05/2025
5.0.3 58 09/05/2025
5.0.2 59 09/05/2025
5.0.1.1 63 09/05/2025
5.0.0 59 09/05/2025
4.1.14 57 09/05/2025
4.1.13 59 09/05/2025
4.1.12 60 09/05/2025
4.1.11 57 09/05/2025
4.1.10 58 09/05/2025
4.1.9 61 09/05/2025
4.1.8 57 09/05/2025
4.1.7 58 09/05/2025
4.1.6 58 09/05/2025
4.1.5 59 09/05/2025
4.1.4 60 09/05/2025
4.1.3.1 59 09/05/2025
4.1.3 60 09/05/2025
4.1.2 62 09/05/2025
4.1.1 60 09/05/2025
4.1.0 59 09/05/2025
4.0.17 58 09/05/2025
4.0.16 58 09/05/2025
4.0.14 56 09/05/2025
4.0.13 58 09/05/2025
4.0.12 60 09/05/2025
4.0.11 62 09/05/2025
4.0.10 61 09/05/2025
4.0.9 57 09/05/2025
4.0.8 63 09/05/2025
4.0.7 57 09/05/2025
4.0.6 60 09/05/2025
4.0.5 59 09/05/2025
4.0.4 59 09/05/2025
4.0.3 55 09/05/2025
4.0.2 60 09/05/2025
4.0.1 59 09/05/2025
4.0.0 60 09/05/2025
4.0.0-rc1 61 09/05/2025
4.0.0-preview2 61 09/05/2025
4.0.0-preview1 61 09/05/2025
3.2.7 57 09/05/2025
3.2.6 57 09/05/2025
3.2.5 63 09/05/2025
3.2.4.1 58 09/05/2025
3.2.4 63 09/05/2025
3.2.3 57 09/05/2025
3.2.2 63 09/05/2025
3.2.1 59 09/05/2025
3.2.0 62 09/05/2025
3.1.10 60 09/05/2025
3.1.9 58 09/05/2025
3.1.8 60 09/05/2025
3.1.7 63 09/05/2025
3.1.6 64 09/05/2025
3.1.5 58 09/05/2025
3.1.4 59 09/05/2025
3.1.3 61 09/05/2025
3.1.2 64 09/05/2025
3.1.1 62 09/05/2025
3.1.0 62 09/05/2025
3.0.8 63 09/05/2025
3.0.7 60 09/05/2025
3.0.6 61 09/05/2025
3.0.5 64 09/05/2025
3.0.4 64 09/05/2025
3.0.3 66 09/05/2025
3.0.2 62 09/05/2025
3.0.1 69 09/05/2025
3.0.0 74 09/05/2025
2.2.7 58 09/05/2025
2.2.6 60 09/05/2025
2.2.5 57 09/05/2025
2.2.4.3 61 09/05/2025
2.2.4.1 63 09/05/2025
2.2.3 61 09/05/2025
2.2.2 58 09/05/2025
2.2.1 62 09/05/2025
2.2.0 63 09/05/2025
2.1.3 58 09/05/2025
2.1.2 62 09/05/2025
2.1.1 59 09/05/2025
2.1.0 60 09/05/2025
2.0.14.3 58 09/05/2025
2.0.12.1 56 09/05/2025
2.0.11 56 09/05/2025