DeviceInfo Module
Complete API documentation for the DeviceInfo module. Read the availability badge definitions before choosing an API.
The native build minimums are iOS 15.1 and Android API 24. Dependencies can require higher minimums. Web entry points and fallbacks were added in v1.8.0.
Import
Core Device Information (9 APIs)
Synchronous properties providing instant access to basic device identity.
deviceId: string
Since v0.1.0 iOS 15.1+ Android API 24+ Web: fallback
Device model identifier.
brand: string
Since v0.1.0 iOS 15.1+ Android API 24+ Web: limited
Device brand/manufacturer name.
model: string
Since v0.1.0 iOS 15.1+ Android API 24+ Web: fallback
Device model marketing name. Maps the hardware identifier to a human-readable name, falling back to a generic name for unknown devices.
systemName: string
Since v0.1.0 iOS 15.1+ Android API 24+ Web: limited
Operating system name.
systemVersion: string
Since v0.1.0 iOS 15.1+ Android API 24+ Web: fallback
Operating system version string.
deviceType: DeviceType
Since v0.1.0 iOS 15.1+ Android API 24+ Web: fallback
Device type category.
uniqueId: string
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get unique device identifier.
- iOS: Reads the current IDFV, or
""when unavailable. Do not assume that it survives removal of all apps from the vendor. - Android: Reads ANDROID_ID, or
""when unavailable. Its scope and reset behavior depend on Android.
Do not use this value as a permanent device identity or account identifier. See Apple IDFV and Android ANDROID_ID.
manufacturer: string
Since v1.2.0 iOS 15.1+ Android API 24+ Web: limited
Get device manufacturer name.
deviceName: string
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get user-assigned device name.
Device Capabilities (7 APIs)
Boolean checks for device features and hardware availability.
isTablet: boolean
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Check if device is a tablet.
- iOS: Based on UIDevice.userInterfaceIdiom
- Android: Based on smallest screen width >= 600dp
isEmulator: boolean
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Check if running in simulator/emulator.
deviceYearClass: number
Since v1.4.2 iOS 15.1+ Android API 24+ Web: fallback
Get estimated device year class based on hardware specifications.
Returns an estimated "year class" representing when this device's hardware would have been considered flagship/high-end. Based on extended Facebook device-year-class algorithm updated for 2025.
RAM → Year Class mapping:
isCameraPresent: boolean
Since v1.2.0 iOS 15.1+ (since v1.9.0) Android API 24+ Web: fallback
The iOS implementation is available from v1.9.0. Published versions through v1.8.3 return true unconditionally. See the implementation change.
Check if camera hardware is available. On iOS, returns false on the simulator or when no video capture device exists. This check does not request camera permission; a true result does not mean the app has permission to capture video.
isPinOrFingerprintSet: boolean
Since v1.2.0 iOS 15.1+ (since v1.9.0) Android API 24+ Web: fallback
The iOS implementation is available from v1.9.0. Published versions through v1.8.3 return false unconditionally. See the implementation change.
Check if PIN, fingerprint, or Face ID is configured. On iOS, checks whether device-owner authentication is available, including the device passcode fallback when biometrics are unavailable or locked out. Returns false when no passcode is set. This check does not authenticate the user or show a prompt; the result is checked again on each read.
isHardwareKeyStoreAvailable: boolean
Since v1.2.1 iOS 15.1+ Android API 24+: limited Web: fallback
Check platform key-storage availability. Android does not verify hardware backing.
Platform limits: iOS checks Secure Enclave availability. Android only checks whether AndroidKeyStore can be opened; it does not prove that a key is hardware-backed.
isLowRamDevice: boolean
Since v1.2.0 iOS: fallback Android API 24+ Web: fallback
Check if device is classified as low RAM device.
Platform: Android. The OS classification API exists from API 19, but this package requires API 24+.
Display & Screen (7 APIs)
Screen and display-related properties.
getHasNotch(): boolean
Since v1.3.0 iOS 15.1+ Android: fallback Web: fallback
Check if device has a display notch.
- iOS only - Detects iPhone X and later models
- Android: Always returns
false
getHasDynamicIsland(): boolean
Since v1.3.0 iOS 16+ Android: fallback Web: fallback
Check if device has Dynamic Island.
- iOS 16+ only - iPhone 14 Pro and later
- Android: Always returns
false
isDisplayZoomed: boolean
Since v1.2.0 iOS 15.1+ Android: fallback Web: fallback
Check if iOS Display Zoom is enabled.
Platform: iOS only
getIsLandscape(): boolean
Since v1.3.0 iOS 15.1+ Android API 24+ Web: limited
Check if device is in landscape orientation.
getBrightness(): number
Since v1.1.0 iOS 15.1+ Android: fallback Web: fallback
Get current screen brightness level (0.0 to 1.0).
Platform: iOS only
getFontScale(): number
Since v1.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get current font scale multiplier.
isLiquidGlassAvailable: boolean
Since v1.2.1 iOS 26+ Android: fallback Web: fallback
Check if the liquid glass effect is available on the device.
Platform: iOS 26.0+
Requires a Swift 6.2+ compiler. Returns false on older compiler builds or when UIDesignRequiresCompatibility is enabled.
System Resources (7 APIs)
Memory, storage, and uptime information.
totalMemory: number
Since v1.2.0 iOS 15.1+ Android API 24+ Web: limited
Get total device RAM in bytes.
getUsedMemory(): number
Since v0.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get current app memory usage in bytes. On iOS this is phys_footprint, the value jetsam and Xcode's memory gauge use.
maxMemory: number
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get maximum memory available to app (in bytes).
On iOS, maxMemory is -1 when os_proc_available_memory() returns 0: no limit applies (e.g. the Simulator) or the app has already exceeded its limit.
On Android, maxMemory and getUsedMemory() are not comparable: maxMemory is the Java heap limit, while getUsedMemory() is the PSS of the whole process, including native memory. getUsedMemory() / maxMemory is only meaningful on iOS.
totalDiskCapacity: number
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get total internal storage size in bytes.
getFreeDiskStorage(): number
Since v0.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get available free storage space in bytes.
getUptime(): number
Since v1.4.2 iOS 15.1+ Android API 24+ Web: fallback
Get device uptime since boot in milliseconds, excluding deep sleep time.
On iOS, use this clock only for app-event timing: elapsed time or timers (35F9.1), or app-event uptime converted into an absolute timestamp using startupTime (8FFB.1). Do not display or collect raw uptime as general device information, send it off-device, or use it for fingerprinting. Only elapsed time between app events or the resulting absolute app-event timestamps may be sent off-device.
Platform behavior:
- iOS: Uses
systemUptime(excludes deep sleep) - Android: Uses
uptimeMillis()(excludes deep sleep)
Both platforms return consistent "active time" since boot, matching the behavior of expo-device.getUptimeAsync().
startupTime: number
Since v1.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get device boot time (milliseconds since epoch).
On iOS, use this value only as the time base for converting app-event uptime into an absolute timestamp (8FFB.1). Do not display or collect the raw boot timestamp as general device information, send it off-device, or use it for fingerprinting. Only the resulting absolute timestamps of events within the app may be sent off-device.
This is the device boot time, not app startup time. See iOS Privacy Manifest for the supported purposes and Apple's usage limits.
Battery & Power (4 APIs)
Battery and power state information.
getBatteryLevel(): number
Since v0.1.0 iOS 15.1+ Android API 24+ Web: limited
Get current battery level (0.0 to 1.0), or -1 if unavailable. A known empty battery returns 0.
On web, battery getters read the live BatteryManager after the initial async
request resolves. Before resolution, or if the API is unavailable or denied,
level is -1, charging is false, battery state is "unknown", and
isLowBatteryLevel() returns false.
getPowerState(): PowerState
Since v0.1.0 iOS 15.1+ Android API 24+: limited Web: limited
On Android, lowPowerMode is always false. Battery level and charging state are implemented.
Get comprehensive power state information.
PowerState interface:
getIsBatteryCharging(): boolean
Since v1.3.0 iOS 15.1+ Android API 24+ Web: limited
Check if battery is currently charging.
isLowBatteryLevel(threshold: number): boolean
Since v1.1.0 iOS 15.1+ Android API 24+ Web: limited
Check if a valid battery level is below threshold. Returns false for an unavailable reading; a known 0% reading still counts as low.
Application Metadata (9 APIs)
App bundle and version information.
version: string
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get application version string.
buildNumber: string
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get application build number.
bundleId: string
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get bundle ID (iOS) or package name (Android).
applicationName: string
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get application display name.
readableVersion: string
Since v1.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get human-readable version string (version.buildNumber).
getFirstInstallTime(): Promise<number>
Since v0.1.0 iOS 15.1+: limited Android API 24+ Web: fallback
On iOS, this estimates installation time from the Documents directory creation time. It returns 0 when unavailable.
Get timestamp when app was first installed (ms since epoch).
getLastUpdateTime(): Promise<number>
Since v0.1.0 iOS 15.1+: limited Android API 24+ Web: fallback
Get timestamp of most recent app update (ms since epoch).
iOS limitation: Reads the Documents directory modification time, not an App Store update timestamp. Returns 0 if unavailable.
firstInstallTimeSync: number
Since v1.1.0 iOS 15.1+: limited Android API 24+ Web: fallback
On iOS, this caches the Documents directory creation time on first access. It returns 0 when unavailable.
Synchronous version of getFirstInstallTime().
lastUpdateTimeSync: number
Since v1.1.0 iOS: fallback Android API 24+ Web: fallback
Synchronous variant (returns -1 on iOS).
Network (6 APIs)
Network connectivity APIs (excluding carrier).
getIpAddress(): Promise<string>
Since v0.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get device local IP address.
getIpAddressSync(): string
Since v1.3.0 iOS 15.1+ Android API 24+ Web: fallback
Synchronous variant (with 5-second cache).
getMacAddress(): Promise<string>
Since v0.1.0 iOS: fallback Android API 24+ Web: fallback
Get the Wi-Fi MAC address when Android allows access. Android uses the same 5-second cache as getMacAddressSync() and returns "unknown" when the address is unavailable. Non-system apps generally cannot access hardware MAC addresses on modern Android; this API does not bypass those restrictions.
getMacAddressSync(): string
Since v1.3.0 iOS: fallback Android API 24+ Web: fallback
Synchronous variant, sharing the same Android lookup, 5-second cache, and "unknown" fallback.
getUserAgent(): Promise<string>
Since v1.1.0 iOS 15.1+ Android API 24+ Web: limited
Get HTTP User-Agent string.
iOS initializes a WebView and caches the first successful result. Android queries WebSettings asynchronously. Both platforms return a Promise<string>.
getIsAirplaneMode(): boolean
Since v1.3.0 iOS: fallback Android API 24+ Web: fallback
Check if airplane mode is enabled.
On web this always returns false: browsers cannot determine airplane mode.
Being offline does not establish that airplane mode is enabled.
Platform: Android only
Carrier Information (7 APIs)
Cellular carrier data for telecom apps, analytics, and geo-detection.
getCarrier(): Promise<string>
Since v0.1.0 iOS 15.1+ (since v1.8.0) Android API 24+ Web: fallback
iOS has a functional implementation from v1.8.0. Earlier async versions return a fixed fallback, even when a synchronous counterpart is implemented. See the iOS implementation change.
Get cellular carrier name.
getCarrierSync(): string
Since v1.3.0 iOS 15.1+ Android API 24+ Web: fallback
Synchronous variant (with 5-second cache).
carrierAllowsVOIP: boolean
Since v1.5.0 iOS 15.1+ Android: fallback Web: fallback
Check if carrier allows VoIP calls on its network.
Platform: iOS only (always returns true on Android)
carrierIsoCountryCode: string
Since v1.5.0 iOS 15.1+ Android API 24+ Web: fallback
Get ISO 3166-1 alpha-2 country code for the carrier.
mobileCountryCode: string
Since v1.5.0 iOS 15.1+ Android API 24+ Web: fallback
Get Mobile Country Code (MCC) per ITU-T Recommendation E.212.
Common MCC values:
mobileNetworkCode: string
Since v1.5.0 iOS 15.1+ Android API 24+ Web: fallback
Get Mobile Network Code (MNC) that identifies the carrier within a country.
mobileNetworkOperator: string
Since v1.5.0 iOS 15.1+ Android API 24+ Web: fallback
Get combined MCC + MNC string.
Use cases:
- Carrier-specific feature toggling
- Regional content delivery
- Telecom analytics
- Fraud detection (geo-location verification)
Audio Accessories (4 APIs)
Audio device detection.
isHeadphonesConnected(): Promise<boolean>
Since v0.1.0 iOS 15.1+ (since v1.8.0) Android API 24+ Web: fallback
iOS has a functional implementation from v1.8.0. Earlier async versions return a fixed fallback, even when a synchronous counterpart is implemented. See the iOS implementation change.
Check if headphones are connected (wired or Bluetooth). On Android, this uses the same output-device detection as the synchronous getter.
getIsHeadphonesConnected(): boolean
Since v1.3.0 iOS 15.1+ Android API 24+ Web: fallback
Synchronous variant.
getIsWiredHeadphonesConnected(): boolean
Since v1.3.0 iOS 15.1+ Android API 24+ Web: fallback
Check if wired headphones are connected. On Android, this includes wired headphones/headsets and USB headsets on API 26+. Built-in speakers and Bluetooth devices do not count as wired headphones.
getIsBluetoothHeadphonesConnected(): boolean
Since v1.3.0 iOS 15.1+ Android API 24+ Web: fallback
Check if Bluetooth headphones are connected.
Location Services (3 APIs)
Location provider information.
isLocationEnabled(): Promise<boolean>
Since v0.1.0 iOS 15.1+ (since v1.8.0) Android API 24+ Web: fallback
iOS has a functional implementation from v1.8.0. Earlier async versions return a fixed fallback, even when a synchronous counterpart is implemented. See the iOS implementation change.
Check if location services are enabled.
getIsLocationEnabled(): boolean
Since v1.3.0 iOS 15.1+ Android API 24+ Web: fallback
Synchronous variant.
getAvailableLocationProviders(): string[]
Since v1.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get list of enabled location providers.
Localization (1 API)
Language and regional settings.
systemLanguage: string
Since v1.3.0 iOS 15.1+ Android API 24+ Web: limited
Get device system language in BCP 47 format.
Examples:
Use Case:
CPU & Architecture (3 APIs)
Processor and ABI information.
supportedAbis: string[]
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get supported CPU architectures.
supported32BitAbis: string[]
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get list of supported 32-bit ABIs.
Platform: Android API 21+, returns [] on iOS
supported64BitAbis: string[]
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get list of supported 64-bit ABIs.
Android Platform (20+ APIs)
Android-specific APIs and build information.
apiLevel: number
Since v1.2.0 iOS: fallback Android API 24+ Web: fallback
Get Android API level.
Platform: Android only
navigationMode: NavigationMode
Since v1.3.0 iOS: fallback Android API 24+ Web: fallback
Get Android navigation mode.
Type: 'gesture' | 'buttons' | 'twobuttons' | 'unknown'
Platform: Android only (returns "unknown" on iOS)
Values:
Use Case:
Note: Navigation mode detection requires Android 10 (API 29) or later. On older Android versions, returns "buttons" since gesture navigation was not available.
getHasGms(): boolean
Since v1.3.0 iOS: fallback Android API 24+ Web: fallback
Check if Google Mobile Services is available.
Platform: Android only
getHasHms(): boolean
Since v1.3.0 iOS: fallback Android API 24+ Web: fallback
Check if Huawei Mobile Services is available.
Platform: Android (Huawei devices) only
hasSystemFeature(feature: string): boolean
Since v1.1.0 iOS: fallback Android API 24+ Web: fallback
Check if specific system feature is available.
Platform: Android only
Common features:
android.hardware.cameraandroid.hardware.nfcandroid.hardware.bluetoothandroid.hardware.wifi
systemAvailableFeatures: string[]
Since v1.2.0 iOS: fallback Android API 24+ Web: fallback
Get list of all available system features.
Platform: Android only
supportedMediaTypeList: string[]
Since v1.2.0 iOS: fallback Android API 24+ Web: fallback
Get list of supported media/codec types.
Platform: Android only
Android Build Information
Synchronous properties providing Android system build information.
Platform: Android only (all return "unknown" or default values on iOS)
serialNumber is cached on first access. Android 8–9 requires a granted READ_PHONE_STATE permission. Android 10+ restricts ordinary apps even with that permission.
iOS Platform (2 APIs)
iOS-specific APIs.
getDeviceToken(): Promise<string>
Since v1.1.0 iOS 15.1+ Android: rejects Web: rejects
Get Apple DeviceCheck token.
Platform: iOS. DeviceCheck exists from iOS 11, but this package requires iOS 15.1+. Rejects on Android.
syncUniqueId(): Promise<string>
Since v1.1.0 iOS 15.1+ Android: ID only Web: fallback
Write the current IDFV to an app-specific Keychain item on iOS. This method does not enable iCloud Keychain synchronization or restore an earlier IDFV.
Platform: iOS (no-op on Android)
Installation & Distribution (3 APIs)
App installation and distribution metadata.
installerPackageName: string
Since v1.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get package name of the app store that installed this app.
getInstallReferrer(): Promise<string>
Since v1.1.0 iOS: fallback Android API 24+ Web: fallback
Get install referrer information (Android Play Store).
Platform: Android only (requires Google Play Services)
isSideLoadingEnabled(): boolean
Since v1.4.2 iOS: fallback Android API 24+ Web: fallback
Check if sideloading (installing from unknown sources) is enabled.
Platform behavior difference:
- Android 7 and below: Returns whether the device allows unknown sources globally (checks
Settings.Global.INSTALL_NON_MARKET_APPS) - Android 8.0+: Returns whether THIS APP has permission to install other apps (per-app permission via
canRequestPackageInstalls()) - iOS: This API always returns
false; it does not detect sideloading.
Important: On Android 8.0+, even if the user has enabled "Install unknown apps" for other apps, this will return false unless they specifically granted permission to this app.
Use cases:
- Security policy enforcement
- Distribution channel detection
- Enterprise deployment verification
Platform: Android (returns false on iOS)
Legacy Compatibility (2 APIs)
Deprecated APIs for backward compatibility.
totalDiskCapacityOld: number
Since v1.2.0 iOS 15.1+ Android API 24+ Web: fallback
Get total disk capacity using legacy Android API.
getFreeDiskStorageOld(): number
Since v1.1.0 iOS 15.1+ Android API 24+ Web: fallback
Get free disk storage using legacy Android API.
Unsupported compatibility properties
These names exist for API compatibility. This package has no Windows native target. They return fixed defaults on iOS, Android, and web.
Performance Notes
Synchronous properties and methods run on the calling thread. Some query the OS or initialize a cache, so synchronous does not mean instantaneous.
Promise-based methods do not have a guaranteed completion time. On iOS, getUserAgent() initializes a WebView on its first successful call and caches that result. Avoid repeated calls to expensive APIs during rendering.
Caching
These synchronous methods use a five-second cache:
getIpAddressSync()getMacAddressSync()getCarrierSync()
A cache refresh queries the OS. Values can remain stale until the next call after expiry. For continuously changing battery or audio state, use React hooks.
Measure latency in your app with its actual device, OS, build mode, and cache state.
Platform Compatibility Matrix
Support differs between members in the same category. Use the badges beside each API or grouped property above. See badge definitions and web limitations.
Next Steps
- View Type Definitions for TypeScript types
- Check out Usage Examples
- Read the Migration Guide for upgrading from
react-native-device-info
