This is a short tutorial explaining how to get the raw number of subscribers from your Feedburner feed to display on your web page.


To do this simple trick we are going to use three things:

  • Feedburner Awareness API (which you don’t need to activate for this)
  • cURL (should be enabled on most servers)
  • PHP 5 (to read the XML we need a PHP5+ function)

I’m assuming here you have a Feedburner account with an active feed.


So onto the php.

$feeduri = "progtuts"; //The bit that comes after
//This is the old Feedburner url
//$url = "". $feeduri;
//This is the new Google Feedburner url
$url="". $feeduri;
$ch = curl_init(); //Use cURL
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //Return data rather then echo it
curl_setopt($ch, CURLOPT_URL, $url); //Pass in our url
$data = curl_exec($ch);
$xml = new SimpleXMLElement($data); //Read the returned XML
$count = $xml->feed->entry['circulation']; //Get our subscriber count

Thats it. Very simple. All we are doing here is using cURL to retrieve the XML output by the Feedburner API and convert it into a php variable. You can now use $count however you want.


To see an example of this view the demo below. I hope you find this little trick useful.

View the Demo

Related Posts


If you enjoyed this post, please consider promoting it.
  • Digg
  • StumbleUpon
  • Design Float
  • Reddit
  • Mixx
  • Technorati

Remeber to subscribe to the feed and get future articles delivered to your feed reader.

If you want to discuss this tutorial or any other thoughts you have then you can do so over on our fourm.


  1. This no longer works, according to your demo page. it says that there is a fatal exception.

  2. it’s works for my browser…

  3. I fixed the script so it should work now.

Leave a Comment