Download NHibernate

NHibernate is a free open-source ORM framework for .NET that maps C# objects to relational databases with automatic SQL generation, caching, and LINQ support.

Download
  • Publisher:
    NHibernate Team
  • Version:
    5.6.0
  • License:
    Free
  • File Size:
    8,6 MB
  • Downloads:
    5464
  • Updated:
    15/11/2025
  • Requirements:
    Windows7,8,10,11

NHibernate is a free, open-source Object-Relational Mapping (ORM) framework for .NET that enables developers to map .NET objects to relational database tables without writing manual SQL queries. It is a port of the widely used Java Hibernate framework and provides a mature, battle-tested data access layer for .NET applications.

With NHibernate, you define mappings between your C# or VB.NET classes and database tables using XML mapping files or Fluent NHibernate’s code-based configuration. The framework then handles all SQL generation, connection pooling, caching, and lazy loading automatically, allowing developers to focus on business logic rather than data access plumbing.

NHibernate supports all major relational databases including SQL Server, MySQL, PostgreSQL, Oracle, and SQLite. It provides a powerful query interface through HQL (Hibernate Query Language), LINQ, and Criteria API, offering flexibility for both simple and complex data access scenarios.

Key Features

  • Object-relational mapping with XML or Fluent NHibernate code-based configuration
  • Automatic SQL generation for CRUD operations
  • First and second-level caching for improved performance
  • Lazy and eager loading of related entities
  • Query via HQL, LINQ, Criteria API, and native SQL
  • Supports SQL Server, MySQL, PostgreSQL, Oracle, SQLite, and more
  • Free and open-source under the LGPL license
NHibernate ORM mapping configuration and database schema NHibernate session factory and query API in .NET project

How to Install

  1. Click the download button or install via NuGet: Install-Package NHibernate
  2. Add NHibernate to your .NET project via the NuGet Package Manager or Package Manager Console.
  3. Create mapping files (HBM XML) or use Fluent NHibernate to define your entity-to-table mappings.
  4. Configure the NHibernate session factory with your database connection string and dialect.
  5. Use ISession to perform queries and transactions in your application code.

Other Versions