Newtonsoft.json issue


I am getting this error:

Could not load file or assembly 'Newtonsoft.Json, Version=, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

I can't seem to fix this, tried adding different Newtonsoft.json dll's. But it just won't run. Let me know what I am doing wrong. Thanks

asked on Stack Overflow Feb 10, 2017 by Michael Philips • edited Sep 4, 2020 by Shady

1 Answer


I commonly see this issue when I have different versions of a library whose types are used across two assemblies. I suggest you check the version of Json.Net is consistent across all your assemblies/dependencies.

If you installed it with nuget in visual studio, try using the 'consolidate' option in the package manage to detect version mismatches. Ensure you also read any compiler warnings (not just errors) as these can help greatly in this case.

answered on Stack Overflow Feb 10, 2017 by Orphid

User contributions licensed under CC BY-SA 3.0