Does OrderedDictionary guarantee preserving insertion order?
20:13 22 Jun 2026

In C#, does OrderedDictionary guarantee that the elements are ordered the same way they were inserted? E.g. this answer suggests it does, but all I find in the documentation is

The elements of an OrderedDictionary are not sorted by the key

Is there any documentation from Microsoft with an affirmative statement about the order of elements? Or is it meant to be guessed/implied?

c# dictionary collections