matomo/device-detector
Parses User-Agent strings and browser Client Hints to identify device type (desktop/tablet/mobile/TV/console), client apps (browsers, media players, feed readers), operating systems, and device brand/model. Composer-ready PHP library.
isBot()) to reduce API abuse or fake traffic in analytics.isConsole()) to offer controller support or optimize graphics settings.device-detector-js).*"This open-source PHP package lets us automatically detect and adapt to any user’s device—from smartphones to smart TVs—with 90%+ accuracy. It’s used by Matomo (3M+ installs) and enables:
*"Pros:
Cons:
Integration:
// 5 minutes to add to Laravel:
composer require matomo/device-detector
$dd = new DeviceDetector($_SERVER['HTTP_USER_AGENT']);
$dd->parse();
if ($dd->isMobile()) { /* ... */ }
Use Cases:
isSmartTV() or isWearable().$dd->isBot()."*How can I help you explore Laravel packages today?