 <p>The things that could have gone wrong are:</p> <ol> <li>The website is not responding</li> <li>The JSON is invalid</li> <li>There is some error in your code</li> </ol> <p>This code should tell your what is happening:</p> <pre><code>error_reporting(-1); // Turn on error reporting $url = "http://natomilcorp.com/api/get-users"; $jsonString = file_get_contents($url); if ( ! $jsonString) { die('Could not get data from: '.$url); } $obj = json_decode($jsonString); if ( ! $obj) { // See the following URL to figure out what the error is // Be sure to look at the comments, as there is a compatibility // function there // http://php.net/manual/en/function.json-last-error-msg.php die('Something is wrong with the JSON'); } echo $obj-&gt;"username"; </code></pre>