Common Issues
1. Android project fails to run
1. Android project fails to run
Problem: Your Android app crashes or fails to build after installing the SDK.Solution:
- Make sure you’ve added the required code in your
AndroidManifest.xmlandres/values/strings.xmlwith your Facebook app settings - Verify you’ve followed all steps in the Android configuration guide
- Check that your Facebook App ID and Client Token are correctly configured
- Ensure your
strings.xmlincludes:
2. Duplicate symbol errors (iOS)
2. Duplicate symbol errors (iOS)
Problem: You get duplicate symbol errors when building for iOS.Solution:Make sure that
FBSDKCoreKit.framework, FBSDKLoginKit.framework, and FBSDKShareKit.framework are not in Link Binary with Libraries for your root project when using CocoaPods.These frameworks should only be linked through CocoaPods, not manually added to your project.3. Build error: 'no type or protocol named UIApplicationOpenURLOptionsKey' (iOS)
3. Build error: 'no type or protocol named UIApplicationOpenURLOptionsKey' (iOS)
Problem: Xcode shows a compilation error about
UIApplicationOpenURLOptionsKey.Solution:Your Xcode version is too old. Upgrade to Xcode 10.0 or later.This type is only available in recent versions of iOS SDK that ship with Xcode 10+.4. Undefined symbols for architecture x86_64 (iOS)
4. Undefined symbols for architecture x86_64 (iOS)
Problem: You get a compilation error with undefined Swift symbols:Solution:After facebook-ios-sdk v7, parts of the SDK are written in Swift. You need to coordinate Swift language usage with Objective-C.Option 1: Add an empty Swift file (Recommended)Option 2: Update PodfileAdd this to the See this issue for more details.
- In Xcode, add a new file named
File.swiftto your main project folder - When Xcode asks if you want to “Create Bridging Header”, click Yes
post_install section of your Podfile, then run pod deintegrate && pod install:5. AppLink.fetchDeferredAppLink does not work (iOS)
5. AppLink.fetchDeferredAppLink does not work (iOS)
Problem: Deferred app links are not working on iOS.Solution:Both the Facebook App and your app must have App Tracking Transparency (ATT) permission granted for Facebook deferred app links to work.Make sure:
- Your app requests ATT permission using
requestTrackingPermissionsAsyncor similar - The user has granted tracking permission to both your app and the Facebook app
- You’ve added
NSUserTrackingUsageDescriptionto yourInfo.plist
6. Exception: 'App ID not found' (iOS)
6. Exception: 'App ID not found' (iOS)
Problem: You get an exception:Solution:If you’re certain that you have the Make sure this initialization happens early in your app’s launch cycle.
FacebookAppID in your Info.plist or that you’ve called Settings.setAppID(), you may be able to fix it by adding the following to your AppDelegate.m inside the application:didFinishLaunchingWithOptions: method, just before the return YES statement:7. Events not showing in Facebook Events Manager
7. Events not showing in Facebook Events Manager
Problem: You’re logging events but they don’t appear in the Facebook Events Manager dashboard.Solution:For events to show up in the Events Manager, you need:
- Run the app on a real device (not simulator)
- Have the Facebook app running in the background and logged in to an account
- Add that Facebook account as an “Advertising Account” for your app in Facebook’s dashboard
- Most important: Have ATT (App Tracking Transparency) enabled on both:
- The Facebook app
- Your app
How to add an Advertising Account:
- Go to Facebook App Dashboard
- Select your app
- Go to Settings > Advanced
- Under Advertising Accounts, add the relevant accounts
8. Login error on Android: 'Error logging you into this application'
8. Login error on Android: 'Error logging you into this application'
Problem: When attempting to log in via the native Facebook app on Android, you get an error: “There is an error in logging you into this application.”Solution:This typically means the appropriate signing certificate hash hasn’t been saved to your Facebook app.
For Development:
-
Generate your development key hash:
(Default password is usually
android) - Add it to your Facebook app dashboard under Settings > Basic > Key Hashes
For Release (Google Play signing):
If Google is signing your releases, you’ll need to get the SHA-1 from the Play Console:- Go to Play Console
- Navigate to Release > App signing > App signing key certificate
- Copy the SHA-1 certificate fingerprint
- Convert it to base64:
- Add the resulting hash to your Facebook app settings
For Internal Testing:
If you’re using App Tester for internal releases:- Get the SHA-1 from Release > Internal app sharing > Internal test certificate
- Run the same command to convert it
- Add that hash as well
9. Forced to use 'limited' login on iOS
9. Forced to use 'limited' login on iOS
Problem: iOS forces the limited login experience even though you didn’t request it.Solution:Although the official documentation doesn’t explicitly state this, the App Tracking Transparency (ATT) permission is required to use the non-limited/default login on iOS devices.Note: This works fine on Android without the permission.
How to fix:
-
Request ATT permission before attempting login:
-
Make sure
NSUserTrackingUsageDescriptionis in yourInfo.plist:
Login Doesn’t Work When Facebook App is Installed
Problem: Login works in the browser but fails when the Facebook app is installed on the device. Solution: Make sure you’ve implemented theopenURL method correctly in your AppDelegate. Without it, the Facebook app cannot redirect back to your app after authentication.
For Objective-C (React Native 0.76 and below):
For Swift (React Native 0.77 and above):
Deep Linking Conflicts with Facebook SSO
Problem: UsingRCTLinkingManager causes Facebook login to fail.
Solution:
Always check Facebook SDK before RCTLinkingManager in the openURL method. If RCTLinkingManager is placed first, it will intercept the Facebook SSO callback URL.
Objective-C:
Swift:
Getting Help
If you’re still experiencing issues:- Check the GitHub Issues for similar problems
- Review the Facebook SDK documentation
- Create a new issue with:
- React Native version
- react-native-fbsdk-next version
- Platform (iOS/Android)
- Complete error messages
- Relevant code snippets