Take the 2-minute tour ×

I used the next code to open my facebook page from ios app :

[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://www.facebook.com/pages/UNNYHOG-Entertainment/208173649242257"]];

And everything was fine, and it's still fine if you don't have a FB app on your device. But if you have it - you will be redirected to https://m.facebook.com/pages/UNNYHOG-Entertainment/208173649242257?id=208173649242257&_rdr

Do anyone knows why does it happening? I guess they made some changes in their app. But what should i do to fix it?

share|improve this question
I don't understand your issue... –  Bot Dec 10 '12 at 18:10
The question is : how can i open facebook page(not a profile, page for ex : facebook.com/pages/UNNYHOG-Entertainment/208173649242257) on iOS 6 with a last version of FB app on a device. The code that i used isn't working anymore. –  Unnyhog Entertainment Dec 10 '12 at 18:17
add comment

1 Answer

up vote 2 down vote accepted

See http://wiki.akosma.com/IPhone_URL_Schemes#Facebook

For a page, you will want to use fb://profile/<page id>


If you want to only use the fb:// url if they have facebook installed then use

if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"fb://"]]) {
    // Facebook app is installed
    fb://profile/<page id>

otherwise use the http:// url

share|improve this answer
Thank you for the response. That works, but only if i have FB app on my device. It's not working without it. Is there any universal way? –  Unnyhog Entertainment Dec 10 '12 at 20:25
@UnnyhogEntertainment I have updated my answer. –  Bot Dec 10 '12 at 20:43
That works, thanks man! ;) –  Unnyhog Entertainment Dec 10 '12 at 21:07
add comment

Your Answer


