1. Conduid
  2. Developer Tools
  3. React Native Nitro Device Info
MCP server · Developer Tools

React Native Nitro Device Info

Device Info at the Speed of Nitro ⚡️

80Excellent

Scored 4 hours ago · breakdown

About React Native Nitro Device Info

React Native Nitro Device Info is an MCP server published by l2hyunwoo in the Developer Tools category: device Info at the Speed of Nitro ⚡️.

The repository has 186 stars and 10 forks, with the last commit 7 days ago. Recent commit activity is the strongest signal that reported issues will get attention.

Install

From source
git clone https://github.com/l2hyunwoo/react-native-nitro-device-info

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Tools (3)

get_apiDetailed info about a specific API

Parameters not published.

list_apisList APIs by category/platform/type

Parameters not published.

search_docsNatural language documentation search

Parameters not published.

Ask AI

✦

Ask AI about React Native Nitro Device Info

Powered by Claude · Grounded in docs

I know everything about React Native Nitro Device Info. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

Static checks derived from the repository 4 hours ago. Heuristics on the source, not an audit.

  • ✓README presentThe repository ships documentation.
  • ✓License declaredUsable under a stated license.
  • ✓Tests presentA test suite exists in the repository.
  • ✓Dependencies pinnedA lockfile pins dependency versions.
  • !No dynamic code executionSource scan found eval or shell execution. Review how tool inputs reach it before granting credentials.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

Releases

react-native-nitro-device-integrity@0.1.0react-native-nitro-device-integrity@0.1.0 · 10 Oct 2026First npm release of `react-native-nitro-device-integrity`. Supports Android Play Integrity (Standard and Classic) and iOS App Attest and DeviceCheck. Send issued tokens to your backend for verification. [Package on…
v1.9.0v1.9.0 · 10 Oct 2026Highlights iOS privacy manifest included in app builds The pod now bundles `PrivacyInfo.xcprivacy` in `NitroDeviceInfo_privacy.bundle`, including Expo prebuild and EAS builds. No privacy-specific config plugin option or manual copy is…
mcp-server-v1.1.0@react-native-nitro-device-info/mcp-server v1.1.0 · 9 Oct 2026@react-native-nitro-device-info/mcp-server v1.1.0 MCP (Model Context Protocol) server for react-native-nitro-device-info AI tool integration. Installation npx @react-native-nitro-device-info/mcp-server or npm install -g…
v1.8.3v1.8.3 · 9 Oct 2026What's Changed Apple Model Updates Added 23 Apple hardware identifiers so `DeviceInfoModule.model` and the compat `getModel()` return marketing names for more devices…
v1.8.2v1.8.2 · 9 Aug 2026What's Changed 131 fix(android): R8 release build crash (@pinpong) 130 chore(deps): bump ip-address from 10.2.0 to 10.4.0 in the npm_and_yarn group across 1 directory (@app/dependabot) 129 chore(deps): bump the npm_and_yarn group across 2…

README

react-native-nitro-device-info

English | 한국어

Get comprehensive device information for React Native using Nitro Modules

📖 Read the full documentation

A high-performance device information library for React Native, built on Nitro Modules for zero-overhead native access through JSI.

Features

  • 🚀 Zero-overhead JSI bindings - Direct JavaScript-to-native communication
  • 📱 100+ device properties - Comprehensive device information
  • 📦 TypeScript-first - Full type definitions included
  • 🔄 Drop-in compatible - Bundled compat layer + codemod for react-native-device-info; familiar expo-device APIs too

Installation

# Using npm
npm install react-native-nitro-device-info react-native-nitro-modules

# Using yarn
yarn add react-native-nitro-device-info react-native-nitro-modules

# Using pnpm
pnpm add react-native-nitro-device-info react-native-nitro-modules

Note: react-native-nitro-modules >=0.35.0 <1.0.0 is required as a peer dependency.

iOS Setup

cd ios && pod install && cd ..

v1.9.0: Privacy manifest bundling is available from 1.9.0 and is not included in 1.8.3. See PR #144.

The pod includes PrivacyInfo.xcprivacy in NitroDeviceInfo_privacy.bundle, including for Expo prebuild / EAS builds. No privacy-specific config plugin option is needed. See iOS Privacy Manifest for the declared API reasons and usage limits.

Upgrading to v1.9.0: An unavailable iOS battery reading changes from 0 to -1; a known empty battery remains 0. useBatteryLevel() and useBatteryLevelIsLow() return null when unavailable. Reinstall pods and rebuild native apps for the iOS capability, privacy-manifest, and Android audio fixes. See the release notes.

Android Setup

No additional configuration needed! Gradle auto-linking handles everything.

Expo (prebuild / dev client)

Use an Expo development build; Expo Go does not include this native module. Rebuild the app after installation or native configuration changes.

npx expo install react-native-nitro-device-info react-native-nitro-modules

Autolinking is enough for most APIs. A few APIs that need a permission or entitlement are opt-in via a config plugin in app.json:

{
  "expo": {
    "plugins": [
      ["react-native-nitro-device-info", { "enableSerialNumber": true }]
    ]
  }
}

Then run npx expo prebuild --clean. See the Expo Setup guide for all options, the device-integrity plugin, and the isSideLoadingEnabled() caveat.

Quick Start

The root export uses native properties and methods. To keep react-native-device-info 15.x-style function calls, use react-native-nitro-device-info/compat. Review the migration caveats.

Synchronous calls do not guarantee a particular latency. Battery getters return -1 when unavailable; battery hooks return null. Use React hooks for changing values.

Basic Usage

import { DeviceInfoModule } from 'react-native-nitro-device-info';

// Synchronous properties
console.log(DeviceInfoModule.deviceId); // "iPhone14,2"
console.log(DeviceInfoModule.systemVersion); // "15.0"
console.log(DeviceInfoModule.brand); // "Apple"
console.log(DeviceInfoModule.model); // "iPhone 13 Pro"

// Synchronous properties
const uniqueId = DeviceInfoModule.uniqueId;
console.log(uniqueId); // "FCDBD8EF-62FC-4ECB-B2F5-92C9E79AC7F9"

const manufacturer = DeviceInfoModule.manufacturer;
console.log(manufacturer); // "Apple"

const isTablet = DeviceInfoModule.isTablet;
console.log(isTablet); // false

// Returns -1 when unavailable; useBatteryLevel() returns null.
const batteryLevel = DeviceInfoModule.getBatteryLevel();
console.log(`Battery: ${batteryLevel >= 0 ? `${(batteryLevel * 100).toFixed(0)}%` : 'unavailable'}`); // "Battery: 85%"

// Asynchronous methods (use inside an async function)
const ipAddress = await DeviceInfoModule.getIpAddress();
console.log(ipAddress); // "192.168.1.100"

const carrier = await DeviceInfoModule.getCarrier();
console.log(carrier); // "T-Mobile"

Advanced Usage

import { DeviceInfoModule } from 'react-native-nitro-device-info';
import type { PowerState, DeviceType } from 'react-native-nitro-device-info';

// Device Identification
const deviceId = DeviceInfoModule.deviceId; // "iPhone14,2"
const manufacturer = DeviceInfoModule.manufacturer; // "Apple"
const uniqueId = DeviceInfoModule.uniqueId; // "FCDBD8EF-..."

// Device Capabilities
const isTablet = DeviceInfoModule.isTablet; // false
const hasNotch = DeviceInfoModule.getHasNotch(); // true
const hasDynamicIsland = DeviceInfoModule.getHasDynamicIsland(); // false
const isCameraPresent = DeviceInfoModule.isCameraPresent; // iOS: camera hardware present; false on simulator, no permission prompt
const isPinOrFingerprintSet = DeviceInfoModule.isPinOrFingerprintSet; // iOS: passcode or biometrics available; no authentication prompt
const isEmulator = DeviceInfoModule.isEmulator; // false
const deviceYearClass = DeviceInfoModule.deviceYearClass; // 2021 (estimated year class)

// System Resources
const resourceReadStartedAt = DeviceInfoModule.getUptime();
const totalMemory = DeviceInfoModule.totalMemory;
const usedMemory = DeviceInfoModule.getUsedMemory();
const totalDisk = DeviceInfoModule.totalDiskCapacity;
const freeDisk = DeviceInfoModule.getFreeDiskStorage();

console.log(
  `RAM: ${(usedMemory / 1024 / 1024).toFixed(0)}MB / ${(totalMemory / 1024 / 1024).toFixed(0)}MB`
);
console.log(
  `Storage: ${(freeDisk / 1024 / 1024 / 1024).toFixed(1)}GB free of ${(totalDisk / 1024 / 1024 / 1024).toFixed(1)}GB`
);
console.log(
  `Resource reads took ${DeviceInfoModule.getUptime() - resourceReadStartedAt}ms`
);

// Battery Information
// Returns -1 when unavailable; useBatteryLevel() returns null.
const batteryLevel = DeviceInfoModule.getBatteryLevel();
const isCharging = DeviceInfoModule.getIsBatteryCharging();
const powerState: PowerState = DeviceInfoModule.getPowerState();

console.log(
  `Battery: ${batteryLevel >= 0 ? `${(batteryLevel * 100).toFixed(0)}%` : 'unavailable'} ${isCharging ? '(charging)' : ''}`
);
console.log(`Low Power Mode: ${powerState.lowPowerMode}`);

// Application Metadata
const version = DeviceInfoModule.version;
const buildNumber = DeviceInfoModule.buildNumber;
const bundleId = DeviceInfoModule.bundleId;
const appName = DeviceInfoModule.applicationName;

console.log(`${appName} (${bundleId})`);
console.log(`Version: ${version} (${buildNumber})`);

// Network & Connectivity (Async)
const ipAddress = await DeviceInfoModule.getIpAddress();
const carrier = await DeviceInfoModule.getCarrier();
const isLocationEnabled = await DeviceInfoModule.isLocationEnabled();

console.log(`IP: ${ipAddress}`);
console.log(`Carrier: ${carrier}`);
console.log(`Location Services: ${isLocationEnabled ? 'enabled' : 'disabled'}`);

// Platform-Specific
const apiLevel = DeviceInfoModule.apiLevel; // Android: 33, iOS: -1
const abis = DeviceInfoModule.supportedAbis; // ["arm64-v8a"]
const hasGms = DeviceInfoModule.getHasGms(); // Android only
const canSideload = DeviceInfoModule.isSideLoadingEnabled(); // Android only

// Device Integrity (Root/Jailbreak Detection) - Local detection only
const isCompromised = DeviceInfoModule.isDeviceCompromised(); // Sync, <50ms
const isCompromisedAsync = await DeviceInfoModule.verifyDeviceIntegrity(); // Async

Android MAC address getters share a 5-second cache and return "unknown" when access is restricted or the Wi-Fi address is unavailable.

Android headphone detection distinguishes wired/USB headsets (USB on API 26+) from Bluetooth; async and sync getters use the same detection.

Need server-verifiable attestation? The local checks above are bypassable. For hardware-backed, server-verified attestation (Play Integrity on Android, App Attest / DeviceCheck on iOS), use the opt-in react-native-nitro-device-integrity package. It issues tokens your backend verifies — see its README.

API Reference

For complete API documentation with all 100+ methods and properties, see API Reference (English).

API sections show introduction-version and platform badges. Read the badge definitions to distinguish OS minimums, limited support, fallbacks, and unreleased implementations.

Quick Reference

Core Properties (Synchronous)

DeviceInfoModule.deviceId; // "iPhone14,2"
DeviceInfoModule.brand; // "Apple"
DeviceInfoModule.systemVersion; // "15.0"
DeviceInfoModule.model; // "iPhone 13 Pro"

Common Properties

// Device Info
DeviceInfoModule.uniqueId; // Sync
DeviceInfoModule.isTablet; // Sync
DeviceInfoModule.totalMemory; // Sync
DeviceInfoModule.getBatteryLevel(); // Sync method
DeviceInfoModule.deviceYearClass; // Sync - estimated device year class
DeviceInfoModule.getUptime(); // Sync - clock for elapsed time between app events

// App Info
DeviceInfoModule.version; // Sync
DeviceInfoModule.bundleId; // Sync

// Platform (Android)
DeviceInfoModule.isSideLoadingEnabled(); // Sync - check sideloading permission

// Network (Async methods)
await DeviceInfoModule.getIpAddress(); // Promise<string>
await DeviceInfoModule.getCarrier(); // Promise<string>

For the complete list of all methods, properties, and detailed documentation, see API Reference (English).

Type Definitions

The library includes full TypeScript definitions. For complete type documentation, see Type Definitions (English).

import type {
  DeviceInfo,
  PowerState,
  BatteryState,
  DeviceType,
} from 'react-native-nitro-device-info';

Migration from react-native-device-info

Use the bundled /compat entry point to migrate react-native-device-info (RNDI) 15.x imports. It adapts function signatures and hook result shapes so call sites can stay unchanged. Platform behavior can differ, and some APIs return placeholders. Review the compatibility caveats and test the APIs your app uses.

# 1. Install
npm install react-native-nitro-device-info react-native-nitro-modules
cd ios && pod install && cd ..

# 2. Rewrite imports automatically (call sites untouched)
npx react-native-nitro-device-info migrate

# 3. Remove the old dependency
npm uninstall react-native-device-info

The codemod rewrites every react-native-device-info import to react-native-nitro-device-info/compat:

// Before
import DeviceInfo from 'react-native-device-info';
import { getModel, useBatteryLevel } from 'react-native-device-info';

// After (rewritten for you — usage is identical)
import DeviceInfo from 'react-native-nitro-device-info/compat';
import { getModel, useBatteryLevel } from 'react-native-nitro-device-info/compat';

The compat layer targets RNDI 15.x; a handful of deprecated/unavailable APIs return documented placeholder values. Want maximum performance? The native API (DeviceInfoModule) offers direct property access and synchronous getters. See the Migration Guide for the full mapping, caveats, and the optional native-API path.

Acknowledgement

Example Apps

This repository includes three example applications to help you get started and test the library:

Showcase App (example/showcase/)

A simple, single-screen app that displays comprehensive device information.

Purpose: Demonstrates the library's API and displays all available device properties.

Running the showcase app:

# From repository root
yarn showcase start  # Start Metro bundler
yarn showcase ios    # Run on iOS
yarn showcase android # Run on Android

# Or from the showcase directory
cd example/showcase
yarn start           # Start Metro bundler
yarn ios             # Run on iOS
yarn android         # Run on Android

Benchmark App (example/benchmark/)

An independent performance testing application for benchmarking the Nitro module.

Purpose: Performance testing, stress testing, and comparison with alternative implementations.

Running the benchmark app:

# From repository root
yarn benchmark start  # Start Metro bundler
yarn benchmark ios    # Run on iOS
yarn benchmark android # Run on Android

# Or from the benchmark directory
cd example/benchmark
yarn start            # Start Metro bundler
yarn ios              # Run on iOS
yarn android          # Run on Android

Integrity Demo App (example/integrity-demo/)

A demo for the opt-in react-native-nitro-device-integrity package. It issues attestation tokens (Play Integrity / App Attest / DeviceCheck) and shows them on screen — verification is left to your server, by design.

Running the integrity demo app:

# From repository root
yarn integrity-demo start   # Start Metro bundler
yarn integrity-demo ios     # Run on iOS (real device required for App Attest)
yarn integrity-demo android # Run on Android (needs Google Play Services)

For more details, see:

MCP Server for AI Integration

Enable AI tools like Claude, Cursor, and Copilot to access accurate library documentation through the MCP (Model Context Protocol) server.

Quick Setup (Recommended)

Run the init command in your React Native project to automatically configure MCP for Cursor and Claude Code:

cd your-react-native-project
npx @react-native-nitro-device-info/mcp-server init

This creates:

  • .cursor/mcp.json - Cursor IDE configuration
  • .mcp.json - Claude Code project configuration

Then restart your IDE and start asking questions!

Manual Configuration

Claude Desktop

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "nitro-device-info": {
      "command": "npx",
      "args": ["@react-native-nitro-device-info/mcp-server"]
    }
  }
}

After saving, restart Claude Desktop completely (Cmd+Q, then reopen).

Cursor IDE

Create .cursor/mcp.json in your project root:

{
  "mcpServers": {
    "nitro-device-info": {
      "command": "npx",
      "args": ["@react-native-nitro-device-info/mcp-server"]
    }
  }
}

Available Tools

Tool Purpose Example Query
search_docs Natural language documentation search "how to get device model"
get_api Detailed info about a specific API "show me getBatteryLevel"
list_apis List APIs by category/platform/type "list all network APIs"

Then ask your AI: "How do I get the device's battery level with react-native-nitro-device-info?"

For complete MCP server documentation, see packages/mcp-server/README.md.

Platform Support

  • iOS: 15.1+
  • Android: API 24+ (Android 7.0 Nougat)
  • Web: import-safe fallback (see below)

Web support

Nitro is a JSI/native technology, so there is no native module in a browser. To keep apps that target both native and web (react-native-web, Next.js SSR) buildable, this package ships a pure-JS web fallback that is selected automatically by your bundler — there is no separate package to install and no import path to change.

// Same import on every platform.
import { DeviceInfoModule } from 'react-native-nitro-device-info';

// On web this returns a fallback value instead of throwing.
console.log(DeviceInfoModule.systemLanguage); // e.g. "en-US" from navigator.language
console.log(DeviceInfoModule.deviceId);       // "unknown" — not available in a browser

The fallback's goal is "does not crash, and returns honest values" — not "does everything." Where a browser API can answer, it does; everything else returns the same neutral constants the native side uses for an unsupported platform ("unknown" / -1 / false / []). Values are never fabricated to look real.

Derived from a real browser API (when available, otherwise the fallback):

Member Source
systemName parsed from navigator.userAgent ("Windows"/"macOS"/"iOS"/"Android"/"Linux", else "web")
systemLanguage navigator.language
brand, manufacturer navigator.vendor
totalMemory navigator.deviceMemory × 1024³ (coarse, spec-bucketed; -1 if unsupported)
getIsLandscape() screen.width > screen.height
getUserAgent() navigator.userAgent
getBatteryLevel(), getPowerState(), getIsBatteryCharging() Battery Status API (navigator.getBattery()), requested once; getters read the live BatteryManager; -1/unknown if the API is absent or denied
getIsAirplaneMode() false (unsupported: browsers cannot determine airplane mode)

Always a fallback constant on web: all Android Build.* fields, carrier/MNC/MCC info, disk/used-memory figures, headphone/location/notch checks, integrity checks (isDeviceCompromised() → false), app metadata (version/bundleId/…), and the Windows-only fields. Promise-returning methods keep their signature and resolve the fallback (they do not reject), except getDeviceToken() which rejects on web — it is Apple DeviceCheck, with no web equivalent, mirroring its behavior on Android.

SSR: the web implementation guards browser globals and returns fallbacks on servers without them. This applies only when the server bundle selects the web implementation. Reading properties, calling methods, or calling createDeviceInfo() through the native entry still requires native bindings and can throw. See Web Support.

Contributing

See CONTRIBUTING.md for development workflow and guidelines.

License

MIT © HyunWoo Lee


Made with ❤️ using Nitro Modules

README fetched from the repository 4 hours ago. The original is authoritative.

Questions

About React Native Nitro Device Info

How do I install React Native Nitro Device Info?

No package has been published for this server, so install it from source: clone the repository and follow its README.

Is React Native Nitro Device Info safe to use with an AI agent?

Its trust score is 80 out of 100 (excellent). It passes 4 of the 6 static security checks run so far; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is React Native Nitro Device Info still maintained?

Yes — the latest release is react-native-nitro-device-integrity@0.1.0 (10 Oct 2026), and the last commit was 7 days ago. The repository has 186 stars.