EntityChange 5.0.14

.NET 6.0 .NET Standard 2.0
There is a newer version of this package available.
See the version list below for details.
dotnet add package EntityChange --version 5.0.14
NuGet\Install-Package EntityChange -Version 5.0.14
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="EntityChange" Version="5.0.14" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add EntityChange --version 5.0.14
#r "nuget: EntityChange, 5.0.14"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install EntityChange as a Cake Addin
#addin nuget:?package=EntityChange&version=5.0.14

// Install EntityChange as a Cake Tool
#tool nuget:?package=EntityChange&version=5.0.14


Library to compare two entity object graphs detecting changes

Build Project

NuGet Version


The EntityChange library is available on nuget.org via package name EntityChange.

To install EntityChange, run the following command in the Package Manager Console

PM> Install-Package EntityChange

More information about NuGet package available at https://nuget.org/packages/EntityChange


  • Compare complete entity graph including child entities, collections and dictionaries
  • Collection compare by index or element equality
  • Dictionary compare by key
  • Custom value string formatter
  • Custom entity equality compare
  • Markdown or Html change report formatter


Configure the Contact properties and collections.

EntityChange.Configuration.Default.Configure(config => config
    .Entity<Contact>(e =>
        // set the FirstName display name
        e.Property(p => p.FirstName).Display("First Name");
        // compare the Roles collection by string equality
        e.Collection(p => p.Roles)
        // set how to format the EmailAddress entity as a string
        e.Collection(p => p.EmailAddresses).ElementFormatter(v =>
            var address = v as EmailAddress;
            return address?.Address;
    .Entity<EmailAddress>(e =>
        e.Property(p => p.Address).Display("Email Address");


Compare to Contact entities

// create comparer using default configuration
var comparer = new EntityComparer();

// compare original and current instances generating change list 
var changes = comparer.Compare(original, current).ToList();

Change Report

Sample output from the MarkdownFormatter


  • Removed Administrator from Roles
  • Changed Email Address from user@Personal.com to user@gmail.com
  • Added user@home.com to Email Addresses
  • Changed Status from New to Verified
  • Changed Updated from 5/17/2016 8:51:59 PM to 5/17/2016 8:52:00 PM
  • Changed Zip from 10026 to 10027
  • Changed Number from 888-555-1212 to 800-555-1212
  • Added Blah to Categories
  • Changed Data from 1 to 2
  • Changed Data from ./home to ./path
Product Versions
.NET net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows net7.0 net7.0-android net7.0-ios net7.0-maccatalyst net7.0-macos net7.0-tvos net7.0-windows
.NET Core netcoreapp2.0 netcoreapp2.1 netcoreapp2.2 netcoreapp3.0 netcoreapp3.1
.NET Standard netstandard2.0 netstandard2.1
.NET Framework net461 net462 net463 net47 net471 net472 net48 net481
MonoAndroid monoandroid
MonoMac monomac
MonoTouch monotouch
Tizen tizen40 tizen60
Xamarin.iOS xamarinios
Xamarin.Mac xamarinmac
Xamarin.TVOS xamarintvos
Xamarin.WatchOS xamarinwatchos
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on EntityChange:

Package Downloads

KickStart Extension for EntityChange library


CQRS framework based on MediatR

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
5.0.21 1,178 12/28/2022
5.0.18 3,652 11/9/2022
5.0.14 247 11/7/2022
5.0.12 209 11/5/2022 6,798 3/31/2021 347 2/15/2021 296 2/15/2021 15,435 4/26/2020 1,442 4/11/2020 21,507 6/6/2019 3,216 11/5/2018 6,034 8/22/2017 12,487 3/6/2017 938 3/4/2017 1,869 7/14/2016 1,483 5/18/2016 968 5/18/2016 976 5/18/2016 957 5/16/2016 964 5/16/2016