Mobile platform detection at backend
Not solved Solved
6 months ago


We have deployed a mobile app on Android using webviews but also have a responsive webapp running on Android smartphones. We need to render different components depending on the type (the webview being so dumb it cannot do the processing!)

I am assessing the use of the 'browser' gem ( to detect which platform/device connects to our backend.

Unlike with iOS, where the gem results in different outputs depending on whether web apps or webview app connects, I cannot figure out how distinguish between both on Android: the combination && results in the same output for both.

Do you have any idea how can distinguish between both, either with browser or else? Thanks

Submit your answer