auto fetch otp from sms

Please provide the following:

  1. SDK Version: 45
  2. Platforms(Android/iOS/web/all): android/ios
  3. Add the appropriate “Tag” based on what Expo library you have a question on.

Is there any option in EXPO of getting the mobile numbers auto-populated for the login screen and auto-fetching OTP from SMS for verification?

Hi @fx-rakesh

I haven’t tried doing this myself, but I have previously come across the following answer:

See also the comment below that about how to do it on iOS.

I was searching for how to do this sort of thing in React Native, since it’s not included in the Expo SDK. If you do that you’ll also find various other possibly useful information.

Note, the libraries mentioned in the answer will not work in Expo Go or with the classic build system. You will need to use EAS Build and you can build a dev client to use instead of Expo Go.

react-native-android-sms-listener and react-native-sms-retriever both look like they should work with EAS Build. Do not run “react-native link” and ignore the “manual installation” steps. react-native-sms-retriever looks newer so if I were doing this I might start with that one.

react-native-get-sms-android looks like it’s for manually reading SMSes. I don’t think that will work these days.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.