PHP Mobile Detector

PHP Mobile Detector

Released 7 years ago , Last update 7 years ago

MobileDetector is a script that will detect if the user is an agent and if possible the mobile type.


  • Detects mobile devices by user agent and accept type
  • Detects the mobile type as well (not always available)

Mobile types

The following mobile types are detected:

  • Android
  • Blackberry
  • Palm OS
  • Windows Mobile
  • iPod
  • iPhone
  • iPad
  • Symbian
  • Generic (no specific device identified)
  • 5 0
  • 4 1
  • 3 0
  • 2 0
  • 1 0
1 Reviews Read Reviews


14 day 14-day money-back guarantee


Personal License

  • Perpetual license

  • 1 site, unlimited servers

  • No distribution (hosted use only)

  • Commercial use


Basic Usage

Here is the basic usage:

require_once( dirname(dirname(__FILE__)) . '/library/MobileDetector.php' );

$detector = new MobileDetector();
$isMobile = $detector-isMobile();

if ($isMobile) {
    $mobileType = $detector-getMobileType();
    echo 'Detected mobile: ' . $mobileType;
} else {
    echo 'Not mobile.';

API documentation

To view all of the available class methods take a look at the API reference.

2 licenses, starting from From » $9.99 View Licenses

Get A Quote

What do you need?
  • Custom development
  • Integration
  • Customization / Reskinning
  • Consultation
When do you need it?
  • Soon
  • Next week
  • Next month
  • Anytime

Thanks for getting in touch!

Your quote details have been received and we'll get back to you soon.

Or enter your name and Email
  • PM perera malinda 5 years ago
  • B bill 7 years ago
    I would like to purchase but I am not a PHP programmer. Will I be able to insert code into my index.html file that will then call your PHP file to do the checking. If this is so, do your instructions show how to enter this into the html file. I am a web developer and this would be very helpful on the Android devices. Thank you in advance.
    • CR Cristian Radu Publisher 7 years ago
      Hello, It depends very much on what you want to do. Normally, you would need to add a snippet of code like the one in the Basic Usage example. In order for that code to be executed, you should put it in a .php file. You can add any HTML file in the .php file as well, so you don't need to worry about that. If you just want to use basic html, you can do something like this: isMobile(); if ($isMobile) { ?>