Retrieve Json data with HttpClient
I am programming for Visual Studio 2011 so I am forced to use HttpClient . I need to retrieve some JSON data from the web, but I guess I need to set the content to "json data" or something because I always get strange characters when using only this code: HttpClient client = new HttpClient(); var response = client.Get("http://api.stackoverflow.com/1.1/users"); var content = response.Content.ReadAsString(); So how can I set the content or what should I do to get the correct data ? edit: Output: something like this: ������ svick The problem is that the response is compressed and HttpClient does