Google is working on WebOTP API. This will allow websites the ability to programmatically obtain the one-time password from a SMS message and automatically fill the form for users with just one tap without switching apps.
Google is working on a feature to enable transferring SMS One Time Passwords (OTPs) from phones to PC with Chrome 93 update. Chrome 93 will support WebOTP (Web One Time Password) interface, this means that the web browser will automatically detect and read the code received on to users’ phone and enter it.
The condition being that users need an Android phone, and both the handset and desktop browser must be signed into the same Google account.
Another critical requirement is that the website they are using should support WebOTP technology. The reason that the feature is for now dependent on the Chromium web engine is why it does not support Apple devices.
Android phone users can already try this feature on Chrome beta page (https://developer.chrome.com/blog/cross-device-webotp/)
Prerequisites
* A desktop or a laptop computer (Windows, Mac, Linux or Chrome OS).
* An Android phone with Google Play Services version 20.30.12 or higher.
* Chrome 93 or later, both on desktop or laptop and mobile. Chrome 93 Beta is available as of late July 2021.
* You need to sign-in to the same Google account on both desktop Chrome and mobile Chrome. For example, via https://myaccount.google.com/ or https://mail.google.com. No need to turn on sync.
* On your Android device, you need to sign-in to Android via “Settings->Google”.
* Chrome 93 must be the default browser on the Android device.
* Chrome 93 must be running either in foreground or background on the Android device.