title: Find out the size of a .NET object
body: <p>I'm trying to find out how much memory my objects take to see how many of them are ending up on the <a href="https://docs.microsoft.com/en-us/dotnet/standard/garbage-collection/large-object-heap" rel="nofollow noreferrer">Large Object Heap</a> (which is anything over 85,000 bytes).</p>
  <p>Is it as simple as adding 4 for an int, 8 for a long, 4 (or 8 if you're on 64 bit) for any reference types etc for each object, or are there overheads for methods, properties, etc.?</p>