# My Android tablet was not detected as a mobile device

**URL:** <https://meta.discourse.org/t/my-android-tablet-was-not-detected-as-a-mobile-device/26734>\
**Category:** Product Support\
**Created:** [Março 25, 2015, 2:35am UTC](https://meta.discourse.org/t/my-android-tablet-was-not-detected-as-a-mobile-device/26734 "2015-03-25T02:35:49Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![trident](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/trident/32/2078_2.png) [@trident](https://meta.discourse.org/u/trident)\
**Post date:** [Março 26, 2015, 3:24am UTC](https://meta.discourse.org/t/my-android-tablet-was-not-detected-as-a-mobile-device/26734/9 "2015-03-26T03:24:42Z")

</div>

It looks like the regex listed [here](https://developer.chrome.com/multidevice/user-agent) should be applied [here.](https://github.com/discourse/discourse/blob/17d07a8b9a3db9d963f9d7d5bd73504984ef3188/lib/mobile_detection.rb#L3) Tablet chrome won’t include “Mobile” as a part of the user agent string; causing this check to fail.

(currently, this checks if the useragent contains “Mobile,” “webOS”, “Nexus 7” or does not contain “iPad”)

The ability to toggle mobile mode on and off seems to be determined [here](https://github.com/discourse/discourse/blob/17d07a8b9a3db9d963f9d7d5bd73504984ef3188/app/assets/javascripts/discourse/initializers/sniff-capabilities.js.es6#L20), but I’m not as sure on that one.

I’m not infront of something to test with for a little while, but I believe something like

```ruby
/iphone|ipad|ipod|(Android.*Chrome\/[.0-9]* (!?Mobile))/

```

might cover these cases better.

---

_[View the full topic](https://meta.discourse.org/t/my-android-tablet-was-not-detected-as-a-mobile-device/26734)._
