AutoMapper 13.0.0

AutoMapper

CI NuGet MyGet (dev)

What is AutoMapper?

AutoMapper is a simple little library built to solve a deceptively complex problem - getting rid of code that mapped one object to another. This type of code is rather dreary and boring to write, so why not invent a tool to do it for us?

This is the main repository for AutoMapper, but there's more:

How do I get started?

First, configure AutoMapper to know what types you want to map, in the startup of your application:

var configuration = new MapperConfiguration(cfg => 
{
    cfg.CreateMap<Foo, FooDto>();
    cfg.CreateMap<Bar, BarDto>();
});
// only during development, validate your mappings; remove it before release
#if DEBUG
configuration.AssertConfigurationIsValid();
#endif
// use DI (http://docs.automapper.org/en/latest/Dependency-injection.html) or create the mapper yourself
var mapper = configuration.CreateMapper();

Then in your application code, execute the mappings:

var fooDto = mapper.Map<FooDto>(foo);
var barDto = mapper.Map<BarDto>(bar);

Check out the getting started guide. When you're done there, the wiki goes in to the nitty-gritty details. If you have questions, you can post them to Stack Overflow or in our Gitter.

Where can I get it?

First, install NuGet. Then, install AutoMapper from the package manager console:

PM> Install-Package AutoMapper

Or from the .NET CLI as:

dotnet add package AutoMapper

Do you have an issue?

First check if it's already fixed by trying the MyGet build.

You might want to know exactly what your mapping does at runtime.

If you're still running into problems, file an issue above.

License, etc.

This project has adopted the code of conduct defined by the Contributor Covenant to clarify expected behavior in our community. For more information see the .NET Foundation Code of Conduct.

AutoMapper is Copyright © 2009 Jimmy Bogard and other contributors under the MIT license.

.NET Foundation

This project is supported by the .NET Foundation.

Showing the top 20 packages that depend on AutoMapper.

Packages Downloads
AutoMapper.Extensions.Microsoft.DependencyInjection
AutoMapper extensions for ASP.NET Core
157
AutoMapper.Extensions.Microsoft.DependencyInjection
AutoMapper extensions for ASP.NET Core
159
AutoMapper.Extensions.Microsoft.DependencyInjection
AutoMapper extensions for ASP.NET Core
165
AutoMapper.Extensions.Microsoft.DependencyInjection
AutoMapper extensions for ASP.NET Core
184
AutoMapper.Extensions.Microsoft.DependencyInjection
AutoMapper extensions for ASP.NET Core
1,058
DHP.Core
Package Description
172
DHP.Core
Package Description
268
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
154
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
155
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
157
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
158
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
159
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
164
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
165
Duende.IdentityServer.EntityFramework.Storage
EntityFramework persistence layer for Duende IdentityServer
167
Nuke.Common
Cross-platform build automation system
154

Version Downloads Last updated
16.1.1 67 03/13/2026
16.1.0 36 03/05/2026
16.0.0 86 12/04/2025
16.0.0-beta-1 67 11/21/2025
15.1.3 34 03/18/2026
15.1.2 41 03/17/2026
15.1.1 46 03/16/2026
15.1.0 114 10/24/2025
15.0.1 126 07/11/2025
15.0.0 99 07/03/2025
14.0.0 489 02/16/2025
13.0.1 563 02/13/2024
13.0.0 8 05/25/2026
12.0.1 571 02/04/2024
12.0.0 163 02/04/2024
11.0.1 144 07/22/2024
11.0.0 190 02/04/2024
10.1.1 186 02/09/2024
10.1.0 7 05/25/2026
10.0.0 133 07/13/2024
9.0.0 126 07/22/2024
8.1.1 127 07/22/2024
8.1.0 140 07/22/2024
8.0.0 123 07/22/2024
7.0.1 156 07/22/2024
7.0.0 7 05/25/2026
7.0.0-alpha-0001 151 07/22/2024
6.2.2 166 07/22/2024
6.2.1 126 07/22/2024
6.2.0 128 07/22/2024
6.1.1 137 07/22/2024
6.1.0 139 07/22/2024
6.0.2 127 07/18/2024
6.0.1 8 05/25/2026
6.0.0 10 05/25/2026
5.2.0 152 07/22/2024
5.1.1 132 07/18/2024
5.1.0 8 05/25/2026
5.0.2 148 07/22/2024
5.0.1 10 05/25/2026
5.0.0 8 05/25/2026
5.0.0-beta-1 147 07/22/2024
4.2.1 135 07/22/2024
4.2.0 156 07/22/2024
4.1.1 132 07/22/2024
4.1.0 8 05/25/2026
4.0.4 139 07/22/2024
4.0.3 7 05/25/2026
4.0.2 8 05/25/2026
4.0.1 8 05/25/2026
4.0.0 9 05/25/2026
4.0.0-ci1061 8 05/25/2026
4.0.0-ci1057 6 05/25/2026
4.0.0-ci1056 7 05/25/2026
4.0.0-ci1054 7 05/25/2026
4.0.0-ci1053 7 05/25/2026
4.0.0-ci1052 7 05/25/2026
4.0.0-ci1051 7 05/25/2026
4.0.0-ci1050 8 05/25/2026
4.0.0-ci1049 10 05/25/2026
4.0.0-ci1046 8 05/25/2026
4.0.0-ci1038 8 05/25/2026
4.0.0-ci1036 9 05/25/2026
4.0.0-ci1034 7 05/25/2026
4.0.0-ci1032 11 05/25/2026
4.0.0-ci1031 7 05/25/2026
4.0.0-ci1026 8 05/25/2026
4.0.0-ci1021 7 05/25/2026
4.0.0-ci1020 10 05/25/2026
4.0.0-ci1019 9 05/25/2026
4.0.0-ci1018 9 05/25/2026
4.0.0-ci1017 6 05/25/2026
4.0.0-ci1015 11 05/25/2026
4.0.0-ci1014 6 05/25/2026
4.0.0-ci1007 8 05/25/2026
4.0.0-ci1006 9 05/25/2026
4.0.0-ci1004 8 05/25/2026
4.0.0-ci1002 8 05/25/2026
4.0.0-alpha1 144 07/22/2024
3.3.1 135 07/22/2024
3.3.0 142 07/22/2024
3.3.0-ci1033 7 05/25/2026
3.3.0-ci1032 9 05/25/2026
3.3.0-ci1031 9 05/25/2026
3.3.0-ci1030 7 05/25/2026
3.3.0-ci1029 11 05/25/2026
3.3.0-ci1028 6 05/25/2026
3.3.0-ci1027 10 05/25/2026
3.3.0-ci1026 9 05/25/2026
3.3.0-ci1025 11 05/25/2026
3.3.0-ci1024 5 05/25/2026
3.3.0-ci1023 7 05/25/2026
3.3.0-ci1022 9 05/25/2026
3.3.0-ci1021 10 05/25/2026
3.3.0-ci1020 11 05/25/2026
3.3.0-ci1019 9 05/25/2026
3.3.0-ci1018 9 05/25/2026
3.3.0-ci1017 8 05/25/2026
3.3.0-ci1016 6 05/25/2026
3.3.0-ci1009 6 05/25/2026
3.3.0-ci1008 9 05/25/2026
3.3.0-ci1007 7 05/25/2026
3.3.0-ci1006 8 05/25/2026
3.3.0-ci1005 8 05/25/2026
3.3.0-ci1004 9 05/25/2026
3.3.0-ci1003 9 05/25/2026
3.3.0-ci1002 8 05/25/2026
3.3.0-ci1001 9 05/25/2026
3.3.0-ci1000 7 05/25/2026
3.2.1 135 07/22/2024
3.2.1-ci1002 6 05/25/2026
3.2.1-ci1001 9 05/25/2026
3.2.1-ci1000 5 05/25/2026
3.2.0 6 05/25/2026
3.2.0-ci1043 7 05/25/2026
3.2.0-ci1042 8 05/25/2026
3.2.0-ci1041 11 05/25/2026
3.2.0-ci1040 8 05/25/2026
3.2.0-ci1039 13 05/25/2026
3.2.0-ci1038 9 05/25/2026
3.2.0-ci1037 8 05/25/2026
3.2.0-ci1036 8 05/25/2026
3.2.0-ci1035 5 05/25/2026
3.2.0-ci1034 10 05/25/2026
3.2.0-ci1033 6 05/25/2026
3.2.0-ci1030 10 05/25/2026
3.2.0-ci1029 6 05/25/2026
3.2.0-ci1028 6 05/25/2026
3.2.0-ci1027 5 05/25/2026
3.2.0-ci1026 7 05/25/2026
3.2.0-ci1025 6 05/25/2026
3.2.0-ci1024 8 05/25/2026
3.2.0-ci1023 9 05/25/2026
3.2.0-ci1022 6 05/25/2026
3.2.0-ci1021 10 05/25/2026
3.2.0-ci1017 11 05/25/2026
3.2.0-ci1016 8 05/25/2026
3.2.0-ci1015 8 05/25/2026
3.2.0-ci1014 6 05/25/2026
3.2.0-ci1011 7 05/25/2026
3.2.0-ci1010 10 05/25/2026
3.2.0-ci1009 7 05/25/2026
3.2.0-ci1008 7 05/25/2026
3.2.0-ci1005 7 05/25/2026
3.2.0-ci1004 7 05/25/2026
3.2.0-ci1003 6 05/25/2026
3.2.0-ci1002 7 05/25/2026
3.2.0-ci1001 8 05/25/2026
3.2.0-ci1000 7 05/25/2026
3.1.1 158 07/22/2024
3.1.1-ci1003 6 05/25/2026
3.1.1-ci1000 6 05/25/2026
3.1.0 154 07/22/2024
3.1.0-ci1058 10 05/25/2026
3.1.0-ci1056 7 05/25/2026
3.1.0-ci1053 8 05/25/2026
3.1.0-ci1051 9 05/25/2026
3.1.0-ci1050 7 05/25/2026
3.1.0-ci1049 8 05/25/2026
3.1.0-ci1048 6 05/25/2026
3.1.0-ci1047 9 05/25/2026
3.1.0-ci1046 9 05/25/2026
3.1.0-ci1045 7 05/25/2026
3.1.0-ci1044 8 05/25/2026
3.1.0-ci1043 8 05/25/2026
3.1.0-ci1038 7 05/25/2026
3.1.0-ci1037 6 05/25/2026
3.1.0-ci1036 8 05/25/2026
3.1.0-ci1035 7 05/25/2026
3.1.0-ci1034 8 05/25/2026
3.1.0-ci1033 8 05/25/2026
3.1.0-ci1032 7 05/25/2026
3.1.0-ci1027 7 05/25/2026
3.1.0-ci1026 7 05/25/2026
3.1.0-ci1024 7 05/25/2026
3.1.0-ci1023 7 05/25/2026
3.1.0-ci1022 7 05/25/2026
3.1.0-ci1021 11 05/25/2026
3.1.0-ci1020 11 05/25/2026
3.1.0-ci1019 7 05/25/2026
3.1.0-ci1018 10 05/25/2026
3.1.0-ci1017 8 05/25/2026
3.1.0-ci1016 9 05/25/2026
3.1.0-ci1014 8 05/25/2026
3.0.0 139 07/22/2024
3.0.0-ci1053 7 05/25/2026
3.0.0-ci1043 9 05/25/2026
3.0.0-ci1042 8 05/25/2026
3.0.0-ci1041 10 05/25/2026
3.0.0-ci1040 9 05/25/2026
3.0.0-ci1039 9 05/25/2026
3.0.0-ci1038 7 05/25/2026
3.0.0-ci1037 8 05/25/2026
3.0.0-ci1036 7 05/25/2026
3.0.0-ci1035 8 05/25/2026
3.0.0-ci1034 8 05/25/2026
3.0.0-ci1033 8 05/25/2026
3.0.0-ci1032 11 05/25/2026
3.0.0-ci1031 7 05/25/2026
3.0.0-ci1029 8 05/25/2026
3.0.0-ci1028 6 05/25/2026
3.0.0-ci1026 8 05/25/2026
2.2.25-ci 7 05/25/2026
2.2.24-ci 9 05/25/2026
2.2.1 139 07/22/2024
2.2.1-ci9006 8 05/25/2026
2.2.1-ci9005 7 05/25/2026
2.2.1-ci9004 8 05/25/2026
2.2.1-ci9003 8 05/25/2026
2.2.1-ci9002 7 05/25/2026
2.2.1-ci9001 7 05/25/2026
2.2.1-ci9000 7 05/25/2026
2.2.1-ci9 5 05/25/2026
2.2.1-ci8 6 05/25/2026
2.2.1-ci7 7 05/25/2026
2.2.1-ci6 7 05/25/2026
2.2.1-ci5 10 05/25/2026
2.2.1-ci4 6 05/25/2026
2.2.1-ci17 7 05/25/2026
2.2.1-ci16 8 05/25/2026
2.2.1-ci11 9 05/25/2026
2.2.1-ci1000 8 05/25/2026
2.2.1-ci10 8 05/25/2026
2.2.0 136 07/22/2024
2.1.267 122 07/22/2024
2.1.266 127 07/22/2024
2.1.265 139 07/22/2024
2.1.262 158 07/22/2024
2.1.1 133 07/22/2024
2.0.0 152 07/22/2024
1.1.2 142 07/22/2024
1.1.1 6 05/25/2026
1.1.0.118 143 07/22/2024