A JavaScript library for detecting browser, OS, device, and layout engine details from the user agent string.
Platform.js is a JavaScript library that detects and provides detailed information about the client's platform, including browser, operating system, device, and layout engine. It parses the user agent string to deliver consistent platform data across different JavaScript environments, from web browsers to server-side Node.js.
JavaScript developers who need reliable client environment detection for analytics, feature gating, debugging, or compatibility handling in web applications, libraries, or tools.
Developers choose Platform.js for its comprehensive detection capabilities, cross-environment consistency, and robust testing across numerous platforms, making it a trusted 'Best in Class' solution for platform identification.
A platform detection library.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Identifies browser, OS, device, and layout engine details, as shown in examples detecting IE on Windows or Safari on iPad with full version and mode info.
Works in browsers, Node.js, AMD loaders, and other JavaScript environments, offering a uniform API for both client and server-side usage.
Can parse arbitrary user agent strings for offline or server-side analysis, demonstrated in the example parsing a complex Opera UA string.
Tested across modern browsers, legacy IE, Node.js versions, and PhantomJS, ensuring robust compatibility as per the support section.
UA strings can be spoofed or inaccurate, leading to potential misdetection, and the library explicitly states it's not a substitute for feature detection.
Detection accuracy depends on regular updates to handle new browsers and devices, which might lag without active maintenance, as hinted in the roadmap wiki.
Limited to platform identification only; developers must implement separate checks for browser capabilities, adding complexity for adaptive features.