flutter_device_info_plus 0.4.0 copy "flutter_device_info_plus: ^0.4.0" to clipboard
flutter_device_info_plus: ^0.4.0 copied to clipboard

Enhanced device information with detailed hardware specs and capabilities. Get comprehensive device data including CPU, memory, storage, sensors, and system information.

flutter_device_info_plus #

pub package popularity likes pub points code style: very good analysis

A Flutter plugin for enhanced device information, providing detailed hardware specifications and capabilities. Access comprehensive device data including CPU, memory, storage, sensors, and system information across all Flutter platforms.

Example demonstration

Features #

  • Hardware Details: Access CPU architecture, core count, frequency, and memory usage (RAM/storage).
  • Display Specs: Read screen resolution, pixel density, and refresh rates.
  • System Information: OS version, build numbers, kernel details, and sensor availability.
  • Web Support: Uses Client Hints, Storage Quota, and Battery Status APIs on supported browsers.
  • Cross-Platform: Consistent API across Android, iOS, macOS, Windows, Linux, and Web.

Installation #

Add this to your pubspec.yaml:

dependencies:
  flutter_device_info_plus: ^0.3.2

Requirements #

  • Dart SDK: >=3.8.0
  • Flutter: >=3.32.0

Important

This plugin's web implementation uses modern JS interop APIs (dart:js_interop). If your app uses an older Flutter/Dart version, you may see build errors related to js_interop. Upgrade your app to Flutter >=3.32.0 and Dart >=3.8.0.

Usage #

Here is a quick example of how to retrieve comprehensive device information:

import 'package:flutter_device_info_plus/flutter_device_info_plus.dart';

void main() async {
  final deviceInfo = FlutterDeviceInfoPlus();
  
  // Get all device data in one call
  final info = await deviceInfo.getDeviceInfo();
  
  print('Device: ${info.deviceName} (${info.brand} ${info.model})');
  print('OS: ${info.operatingSystem} ${info.systemVersion}');
  print('CPU: ${info.processorInfo.architecture} (${info.processorInfo.coreCount} cores)');
  print('RAM: ${info.memoryInfo.totalPhysicalMemory ~/ (1024 * 1024)} MB');
}

Check out the example directory for more advanced usage patterns, including detailed UI representations and real-time monitoring.

Platform Support #

Platform Device Info Hardware Specs Battery Info Sensors Network Info
Android ✔️ ✔️ ✔️ ✔️ ✔️
iOS ✔️ ✔️ ✔️ ✔️ ✔️
Web ✔️ ✔️* ✔️* ✔️ ✔️
Windows ✔️ ✔️ ✔️ ✔️ ✔️
macOS ✔️ ✔️ ✔️ ✔️ ✔️
Linux ✔️ ✔️ Limited ✔️ ✔️

*Enhanced on supporting browsers via Client Hints & Battery API.

Support #

7
likes
160
points
971
downloads

Documentation

API reference

Publisher

verified publisherbechattaoui.dev

Weekly Downloads

Enhanced device information with detailed hardware specs and capabilities. Get comprehensive device data including CPU, memory, storage, sensors, and system information.

Repository (GitHub)
View/report issues

Topics

#device-info #hardware #system-info #platform-info #flutter-plugin

Funding

Consider supporting this project:

github.com

License

BSD-3-Clause (license)

Dependencies

flutter, flutter_web_plugins, web

More

Packages that depend on flutter_device_info_plus

Packages that implement flutter_device_info_plus