Description: I’m using Appwrite with Flutter for Google OAuth login. The authentication flow works fine on iOS and the browser, but on Android devices, after a successful Google sign-in, the redirection back to the app is not working as expected.
Details:
Platform: Flutter (latest), Appwrite SDK (latest)
Login Method: account.createOAuth2Session(provider: 'google',) Behavior on iOS: Works correctly, user is redirected back to the app and the session is created. Behavior on Android: Google login succeeds, but after consent, the redirect does not return to the app. Instead, it either hangs or stays on the browser. Expected Behavior: On success, the user should be redirected back to the app with the session established.
Tried:
- Updated AndroidManifest intent filter for redirect URL.
- <!-- Add this inside the <application> tag, along side the existing <activity> tags --> <activity android:exported="true" android:name="com.linusu.flutter_web_auth_2.CallbackActivity" > <intent-filter android:label="flutter_web_auth_2"> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:scheme="appwrite-callback-<PROJECT_ID>" /> </intent-filter> </activity>*
- Ensured redirect URL matches in Appwrite console and app config.
- Looking for guidance or examples on fixing the Android OAuth redirection issue for Appwrite + Flutter.
Recommended threads
- vorafy.studio domain already exists erro...
My domain vorafy.studio is stuck/locked from a previously deleted project. I created a new project but can't add the domain — getting 'already exists' error. Pl...
- Appwrite (Dart SDK) (for package_info_pl...
Hi team! Many Flutter plugins now need package_info_plus 10.x and device_info_plus 13.x, but appwrite 25.4.0 still constrains package_info_plus: >=8.0.2 <10.0...
- Custom domain for Google Auth
Hello! I connected my custom domain to my Appwrite project, but I can't get the Google login/consent screen to show my domain instead of the Appwrite domain. I...