@VRonin said in QDomDocument toString() producing different results: This would also have licensing implications though Thanks for idea, i think we can build our own QDom* classes and make lib for application. Also possible solution is canonical serializer, that will save xml in right way, but both solutions require much more code than .toString() :) This link demonstrate canonical serializer https://stackoverflow.com/questions/27378143/qt-5-produce-random-attribute-order-in-xml