How to get all the parent classes of a derived class in C# Reflection <p>It is weird that I was not able to find a similar question but this is what actually I want, finding all the parent classes of a derived class. </p> <p>I tested a code with a hope that it works for me :</p> <pre><code>void WriteInterfaces() { var derivedClass = new DerivedClass(); var type = derivedClass.GetType(); var interfaces = type.FindInterfaces((objectType, criteria) =&gt; objectType.Name == criteria.ToString(),"BaseClass"); foreach(var face in interfaces) { face.Name.Dump(); } } interface BaseInterface {} class BaseClass : BaseInterface {} class BaseClass2 : BaseClass {} class DerivedClass : BaseClass2{} </code></pre> <p>Basically, here my main intention is to check if a derived class somehow inherits a base class somewhere in its base hierarchy.</p> <p>However, this code returns null and works only with interfaces.</p>