This is a targeted design decision that no type information is selected for primitive value types, so the values remain as strings.
You either have to deserialize into a strongly typed POCO that contains type information:
public class MixType { public string a { get; set; } public int b { get; set; } public bool c{ get; set; } } var mixedMap = new Dictionary<string, object> { { "a", "text" }, { "b", 32 }, { "c", false }, }; var json = JsonSerializer.SerializeToString(mixedMap); Console.WriteLine("JSON:\n" + json); var mixedType = json.FromJson<MixType>(); Assert.AreEqual("text", mixedType.a); Assert.AreEqual(32, mixedType.b); Assert.AreEqual(false, mixedType.c);
Or deserialize in Dictionary<string,string> and parse it yourself.
Or deserialize using the dynamic ServiceStack API. See the ServiceStack Dynamic JSON Test folder for an example on how to do this.
mythz source share