If I need to return JSON from an MVC controller, and I don’t want to use the C# javascript serializer (because it encodes it weirdly) I will hand role a response looking something like this:

var duns1 = new {Id= "1", Url = "http://111"};
var duns2 = new {Id= "2", Url = "http://222"};

var result = new[] { duns1, duns2};

Doing this, and then browsing it through a browser gives a new clean result:

[{"Id":"1", "Url":"http://111"},{"Id":"2","Url":"http://222"}]

And not the messy result the C# JSON serializer gives me which I can’t use with jQuery:

"[{\"Id\":\"1\",\"Url\":\"http://111\"},{\"Id\":\"2\",\"Url\":\"http://222\"}]"