Get Data From URL Through HttpWebRequest Method In C#

1. Create an aspx page
 
2. Paste below code in page load event.
  1. var url = "www.your-url.com";//Paste ur url here  
  2.   
  3. WebRequest request = HttpWebRequest.Create(url);  
  4.   
  5. WebResponse response = request.GetResponse();  
  6.   
  7. StreamReader reader = new StreamReader(response.GetResponseStream());  
  8.   
  9. string responseText = reader.ReadToEnd();  
  10.   
  11. //if your response is in json format just uncomment below line  
  12.   
  13. //Response.AddHeader("Content-type""text/json");  
  14.   
  15. Response.Write(responseText);