Npgsql.EntityFrameworkCore.PostgreSQL 11.0.0-preview.2

Npgsql Entity Framework Core provider for PostgreSQL

Npgsql.EntityFrameworkCore.PostgreSQL is the open source EF Core provider for PostgreSQL. It allows you to interact with PostgreSQL via the most widely-used .NET O/RM from Microsoft, and use familiar LINQ syntax to express queries. It's built on top of Npgsql.

The provider looks and feels just like any other Entity Framework Core provider. Here's a quick sample to get you started:

await using var ctx = new BlogContext();
await ctx.Database.EnsureDeletedAsync();
await ctx.Database.EnsureCreatedAsync();

// Insert a Blog
ctx.Blogs.Add(new() { Name = "FooBlog" });
await ctx.SaveChangesAsync();

// Query all blogs who's name starts with F
var fBlogs = await ctx.Blogs.Where(b => b.Name.StartsWith("F")).ToListAsync();

public class BlogContext : DbContext
{
    public DbSet<Blog> Blogs { get; set; }

    protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
        => optionsBuilder.UseNpgsql(@"Host=myserver;Username=mylogin;Password=mypass;Database=mydatabase");
}

public class Blog
{
    public int Id { get; set; }
    public string Name { get; set; }
}

Aside from providing general EF Core support for PostgreSQL, the provider also exposes some PostgreSQL-specific capabilities, allowing you to query JSON, array or range columns, as well as many other advanced features. For more information, see the the Npgsql site. For information about EF Core in general, see the EF Core website.

Showing the top 20 packages that depend on Npgsql.EntityFrameworkCore.PostgreSQL.

Packages Downloads
EFCore.BulkExtensions
EntityFramework .Net EFCore EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, MySQL, SQLite
109
EFCore.BulkExtensions
EntityFramework .Net EFCore EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, MySQL, SQLite
164
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete and Read (CRUD) operations on SQL Server, PostgreSQL and SQLite
28
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, MySQL, SQLite
25
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, MySQL, SQLite
26
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, MySQL, SQLite
27
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, MySQL, SQLite
30
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, SQLite
25
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, SQLite
26
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, SQLite
27
EFCore.BulkExtensions
EntityFramework EF Core Bulk Batch Extensions for Insert Update Delete Read (CRUD) operations on SQL Server, PostgreSQL, SQLite
30

.NET 11.0

Version Downloads Last updated
11.0.0-preview.2 3 03/14/2026
11.0.0-preview.1 4 02/12/2026
10.0.1 2 03/14/2026
10.0.0 9 11/23/2025
10.0.0-rc.2 8 10/20/2025
10.0.0-rc.1 10 09/18/2025
10.0.0-preview.7 13 08/20/2025
10.0.0-preview.5 13 06/29/2025
10.0.0-preview.3 14 05/12/2025
10.0.0-preview.2 16 04/02/2025
10.0.0-preview.1 15 03/07/2025
9.0.4 16 03/07/2025
9.0.3 15 01/18/2025
9.0.2 19 01/18/2025
9.0.1 16 01/18/2025
9.0.0-rc.2 17 12/05/2024
9.0.0-rc.1 17 01/18/2025
9.0.0-preview.7 17 01/18/2025
9.0.0-preview.3 13 01/18/2025
9.0.0-preview.2 17 03/27/2024
9.0.0-preview.1 18 03/08/2024
8.0.11 14 01/18/2025
8.0.10 18 01/18/2025
8.0.8 20 01/06/2025
8.0.4 19 01/18/2025
8.0.2 23 03/07/2024
8.0.0 21 03/02/2024
8.0.0-rc.2 17 03/08/2024
8.0.0-rc.1 16 03/28/2024
8.0.0-preview.7 19 03/08/2024
8.0.0-preview.4 18 03/08/2024
8.0.0-preview.3 20 03/08/2024
8.0.0-preview.2 18 03/08/2024
8.0.0-preview.1 19 03/08/2024
7.0.18 18 01/18/2025
7.0.11 19 03/02/2024
7.0.4 244 08/18/2023
7.0.3 18 03/07/2024
7.0.1 24 01/04/2024
7.0.0 19 03/20/2024
7.0.0-rc.2 19 03/07/2024
7.0.0-rc.1 21 03/08/2024
7.0.0-preview.7 21 03/08/2024
7.0.0-preview.6 19 03/08/2024
7.0.0-preview.5 21 03/08/2024
7.0.0-preview.4 17 03/07/2024
7.0.0-preview.3 16 03/07/2024
7.0.0-preview.2 18 03/07/2024
7.0.0-preview.1 20 03/07/2024
6.0.29 15 01/18/2025
6.0.22 19 03/21/2024
6.0.8 18 03/06/2024
6.0.7 17 08/18/2023
6.0.6 18 08/18/2023
6.0.5 17 03/18/2024
6.0.4 21 03/07/2024
6.0.3 18 03/15/2024
6.0.2 20 03/07/2024
6.0.1 20 01/29/2024
6.0.0 18 03/21/2024
6.0.0-rc.2 18 03/08/2024
6.0.0-rc.1 22 03/08/2024
6.0.0-preview7 20 03/08/2024
6.0.0-preview6 17 03/08/2024
6.0.0-preview5 18 03/08/2024
6.0.0-preview4 19 03/08/2024
6.0.0-preview3 19 03/08/2024
6.0.0-preview2 21 03/08/2024
6.0.0-preview1 17 03/08/2024
5.0.10 17 03/08/2024
5.0.7 17 03/07/2024
5.0.6 17 03/07/2024
5.0.5.1 24 03/07/2024
5.0.5 21 03/22/2024
5.0.2 16 03/22/2024
5.0.1 17 03/07/2024
5.0.0 16 03/18/2024
3.1.18 19 03/07/2024
3.1.11 19 03/07/2024
3.1.4 18 03/21/2024
3.1.3 16 03/19/2024
3.1.2 19 03/07/2024
3.1.1.2 16 03/07/2024
3.1.1.1 22 03/07/2024
3.1.1 16 03/21/2024
3.1.0 20 03/07/2024
3.0.1 17 03/15/2024
3.0.0 20 03/21/2024
2.2.4 20 03/02/2024
2.2.0 17 03/15/2024
2.1.2 19 03/21/2024
2.1.1.1 16 03/07/2024
2.1.1 20 03/07/2024
2.1.0 20 03/07/2024
2.0.2 17 03/15/2024
2.0.1 15 03/18/2024
2.0.0 21 03/02/2024
1.1.1 15 03/25/2024
1.1.0 17 03/15/2024
1.0.2 22 03/22/2024
1.0.1 17 03/15/2024
1.0.0 15 03/15/2024