Open Source + Pro Edition

Entity Database
for .NET

Not a key-value store. Real objects, real queries.
LINQ, trees, aggregations, window functions — native SQL.

$ dotnet new install redb.Templates && dotnet new redb -n MyApp
// Define your model
[RedbScheme]
public class Product
{
    public string Name { get; set; }
    public decimal Price { get; set; }
    public Category Category { get; set; }  // Nested!
}

// Query with full LINQ
await redb.Query<Product>()
    .Where(p => p.Price < 100)
    .Where(p => p.Category.Name == "Electronics")
    .OrderBy(p => p.Name)
    .ToListAsync();
100K+ Objects Tested
<15ms Query Time
2 DB Engines
0 Migrations

Why RedBase?

Strong Typing

Real C# classes with IntelliSense. Compile-time checks. Full refactoring. No magic strings.

Tree Structures

Hierarchical data as first-class citizen. Ancestors, descendants — optimized CTE queries.

Full LINQ

Where, OrderBy, GroupBy, Take, Skip, Any, All, Count — all compiled to native SQL.

Analytics

GroupBy, Sum, Avg, Min, Max. Window functions: RowNumber, Rank, Lag, Lead.

Zero Migrations

Code-first sync. Add a property — database updates automatically. No scripts.

Enterprise Ready

PostgreSQL & SQL Server. Caching, change tracking, computed expressions.

Write Less. Query More.

No more Include chains. No N+1 problems.

Traditional Approach
// Nested objects = Include chains
var dbOrders = await context.Orders
    .Include(o => o.Customer)
    .Include(o => o.Items)
        .ThenInclude(i => i.Product)
            .ThenInclude(p => p.Category)
    .Include(o => o.Shipping)
        .ThenInclude(s => s.Address)
    .Where(o => o.Status == "Active")
    .ToListAsync();

// Then map to business objects...
var orders = dbOrders.Select(MapToOrder);

// 6 JOINs, N+1 risk, manual mapping
RedBase
// Query business objects directly
var orders = await redb
    .Query<Order>()
    .Where(o => o.Status == "Active")
    .Where(o => o.Customer.Country == "US")
    .ToListAsync();

// Business entities ready to use
// No DB models. No mapping.
// No Include. Compile-time safe.

Real SQL. Real Power.

Built on PostgreSQL & SQL Server — enterprise databases you already trust.

Full Relational Power

Indexes, foreign keys, transactions, constraints, triggers — everything your SQL server provides. No limitations.

ACID Transactions

Real database transactions with rollback support. Not eventual consistency — immediate, reliable, battle-tested.

Native SQL Performance

Queries compile to optimized SQL. Use EXPLAIN ANALYZE. Add indexes where needed. No black box.

Strong Typing

C# classes with IntelliSense. Compile-time checks. Refactoring works. No magic strings, no runtime surprises.

Custom SQL When Needed

Write raw SQL for complex cases. Mix LINQ and SQL freely. Full control when you need it.

Better Than NoSQL

Flexibility of document stores + power of SQL. Nested objects without JSON parsing. Real queries, not map-reduce.

Perfect For

From simple projects to enterprise systems — one approach for all.

Easy SQL Integration

Have existing SQL database? Just connect, describe your classes, and start working. No migrations, no schema changes. Evolve gradually.

Stored Procedures & Functions

Use your existing library of SQL functions. Create custom procedures. Call them directly from LINQ. Full SQL power in C# code.

IoT & Telemetry

Sensors, devices, controllers — store as RedBase objects. Create your own partitioned trend tables for time-series data. Link via FK to _objects. Best of both worlds.

Identity & IAM

Users, roles, permissions, claims, policies, audit logs. Instead of 20+ ASP.NET Identity tables — just C# classes. Typed, refactorable, simple.

CRM & Business Apps

Contacts, companies, deals, products. Each industry needs different fields. Add custom attributes without ALTER TABLE. Flexible like spreadsheet, typed like code.

No-Code & Builders

Website builders, CMS, form builders. Users create entity types at runtime. You just save objects — no schema generation, no code generation.

Simple Projects

Blog, catalog, portfolio site? Define classes, save objects, query with LINQ. Database ready in minutes. Scale when needed.

Medical & ERP

Hundreds of entity types: patients, diagnoses, tests, equipment, orders. Traditional approach = hundreds of tables. RedBase = just C# classes.

E-commerce

Clothes have size & color. Electronics have specs. Food has expiry. Each category — different attributes. One codebase, no schema per category.

Database Portability

Export to .redb file, import to any supported database. PostgreSQL today, SQL Server tomorrow. One backup format, zero vendor lock-in. CLI tool included.

Future Engines

PostgreSQL & SQL Server today. Oracle, MySQL, SQLite, ClickHouse — on the roadmap. Your code stays the same. Switch engines without rewriting queries.

Cloud & MPP Ready

SQL Server → Azure SQL. PostgreSQL → Aurora, AlloyDB, Citus. GreenPlum compatibility in research. Same code, change connection string — on-prem to cloud in minutes.

.NET Native

Built for .NET developers. Works with C#, F#, VB.NET — any .NET language.

Cross-Platform

Windows, Linux, macOS, Docker, Kubernetes. .NET 8+ with AOT support. Deploy anywhere — same binary.

Debug & Transparency

ToSqlString() on any query — see exact SQL before execution. No black box. Use EXPLAIN ANALYZE. Profile like native SQL.

Parallel Processing

Parallel.ForEach for materialization. Parallel tree diff. Bulk operations. Scales to all CPU cores. 100K+ objects/sec.

Full LINQ Support

Where, Select, OrderBy, GroupBy, Any, All, Count, Take, Skip — everything works. Not a subset. Real LINQ, real power.

Dependency Injection

Standard IServiceCollection. AddRedb() and done. Scoped services, proper lifetime. ASP.NET Core, Blazor, MAUI — native integration.

100% Async

Every operation is async/await. No blocking calls. Perfect for high-load web apps, real-time services, microservices.

Strong Typing

IntelliSense for all properties. Compile-time checks. Refactoring works across codebase. No magic strings, no surprises.

NuGet Ready

dotnet add package redb.Postgres — start coding in seconds. Open source core free forever. Pro packages for enterprise needs.

Engine-Specific SQL

LINQ compiles to optimized SQL for PostgreSQL or SQL Server. Not generic SQL — native syntax, native functions, native performance.

N O D S for .NET

RedBase — Native Object Database on SQL

Object-native. SQL-powered.
Store C# objects directly using PostgreSQL or SQL Server as the engine.
No migrations. Full LINQ. SQL access when you need it.

Start building today

Free open source core. Pro features for enterprise needs.