How to obtain JSON/RSS feed for Facebook Pages without OAuth/GraphAPI

Facebook killed their publicly available RSS feed for Facebook Pages couple of years back in favor of their walled garden approach (GraphAPI). For example, if you go to http://graph.facebook.com/Nike/feed it will ask you for a valid access token which you can get obtain via OAuth Authorization which entails quite a few steps. If you just wanted to display/parse any Facebook Page feed without going through those hoops you are out of luck!

I found myself in a similar situation recently and after some Googling I was able to figure out a workaround. Here’s how it goes:

1) Go to https://developers.facebook.com/tools/explorer

2) Put the username/vanity url of the Facebook Page in question in the request bar and hit Submit. For example, if you wanted to get a feed for: https://www.facebook.com/nike you would put “nike” without quotes in the request bar and click on Submit. (Make sure GET request is selected in the drop-down)

3) Grab the id from the results below and paste it in this URL: https://www.facebook.com/feeds/page.php?id=[FACEBOOK-ID-GOES-HERE]&format=[rss20|json] So for example, if we wanted JSON feed for Nike’s Facebook page, we’d go to: https://www.facebook.com/feeds/page.php?id=15087023444&format=json

BONUS:

You can do the same with Twitter (officially supported):

http://api.twitter.com/1/statuses/user_timeline.[rss|json]?screen_name=[USERNAME-GOES-HERE]&include_rts=[1|0]

So for example, if you wanted to get JSON feed for Nike’s Twitter, you’d go to:

http://api.twitter.com/1/statuses/user_timeline.json?screen_name=nike&include_rts=1

Happy Hacking!

If you have any questions or comments, please post them below. If you liked this post, you can share it with your followers or follow me on Twitter!