How to Debug Your Expo App When It Breaks on a Real Device

DavidDavid August 4, 2026 9 min read
How to debug an Expo app on a real device
Original image, App Store Launch Club

Why Device and Simulator Bugs Are Different Problems

The iOS simulator and Android emulator are fast and convenient development tools, but they are not identical to a real device. Three categories of differences account for most device-only bugs.

  • Native modules: some React Native libraries have device-specific behavior that the simulator does not replicate. Camera, biometrics, NFC, and Bluetooth APIs often fall into this category.
  • Permissions: the simulator often grants permissions automatically or handles them differently than a real device. A camera permission flow that works in the simulator may crash on device if the permission request is not implemented correctly for the OS version.
  • Network conditions: simulators typically share the host computer's network connection. Real devices on cellular or a different WiFi network encounter different latency, NAT behavior, and CORS environments.

Step One: Read the Device Logs

The Metro bundler captures device logs in real time while your app is running on a connected device. These logs include JavaScript errors, console output, and native module messages. They are your first and most important debugging tool.

  1. Connect your device to your Mac with a USB cable.
  2. Run `npx expo start` in your project directory.
  3. Press 'a' for Android or 'i' for iOS to open the app on the connected device.
  4. Reproduce the bug. Watch the terminal window for red error messages.
  5. Copy the full error including the stack trace - not just the first line.

Step Two: Give Claude Code the Full Error

Most Expo device bugs are fixable in one to three turns with Claude Code if you give it the right input. The right input is the full error from the logs - not a description of what you think happened, but the actual error string, the file path it references, and the stack trace.

A prompt that works: 'My Expo app crashes on a real iPhone but not in the simulator. Here is the error from the Metro logs: [paste the full error]. The crash happens when I [describe the action]. Please explain what is causing this and fix it.' Claude Code can usually identify the root cause from the error alone and propose a targeted fix.

Common Device-Only Bug Patterns and Their Fixes

Device-only bug patterns and starting points

SymptomLikely CauseStarting Fix
App crashes on launch only on deviceA native module initializing incorrectlyCheck if a permissions declaration is missing in app.json or Info.plist
Feature works in simulator, fails on deviceDevice-specific native API behaviorTest with console.log before and after the API call to isolate where it fails
Network request works in simulator, fails on deviceDifferent network environment or CORSLog the exact request URL and response status on device - the device may be hitting a different endpoint
App crashes after a few minutes of use on deviceMemory pressure on real hardwareReduce image sizes and check for event listener memory leaks
Permissions prompt never appears on devicePermission not declared in app.jsonAdd the required permission declaration and rebuild the app

When You Cannot Reproduce the Bug on a Connected Device

Some device bugs are intermittent or only occur in production builds, not in development. If you cannot reproduce the bug on a connected device in development mode, the next step is to create a development build using EAS Build - a production-equivalent binary that still shows console logs.

Claude Code can set up the EAS Build configuration if you have not used it yet. Ask it to configure a development build profile in eas.json and give it the result of running `eas build:configure`. A development build gets you closer to production behavior while still giving you readable stack traces. Join the App Store Launch Club at appstorelaunchclub.com for $9/month for the full Claude Code and Expo workflow.

Free app-building tips, straight to your inbox

Short, practical drops on app ideas, validating fast, store listings, and passing app review. No spam, unsubscribe anytime.

Frequently asked questions

Does Claude Code know about Expo-specific APIs?

Yes. Claude Code has strong knowledge of the Expo SDK, Expo Router, EAS Build, and common React Native libraries. When asking it to fix a device bug, mention that the project uses Expo rather than bare React Native so it applies the right context and avoids suggesting native fixes that require ejecting.

My app works in Expo Go but breaks in the production build - why?

Expo Go includes its own set of pre-built native modules. A production build only includes the modules configured in your app.json. If your production build is missing a behavior that works in Expo Go, check whether the relevant library is properly configured in app.json and included in your dependencies.

How do I view crash logs from a deployed app on a real iPhone?

For a deployed app not running through Expo's dev tools, you can connect the iPhone to a Mac and use the Devices window in Xcode to view crash logs. For production monitoring, consider adding a crash reporting library like Sentry to your app - it captures device crashes with stack traces and sends them to a dashboard you can access from any browser.

Where can I learn more about shipping Expo apps with Claude Code?

The App Store Launch Club covers the full build pipeline - from first line of code to shipped app - using Claude Code and Expo. Join at appstorelaunchclub.com for $9/month.

Last reviewed by David on August 4, 2026

David

Written by

David

Founder and app builder

Keep reading

App StoreLaunch

App Store Phased Release: How the 7-Day Rollout Works, How to Pause It, and When to Skip It

App Store phased release rolls a version update out to a random sample of users with automatic updates on over 7 days: 1 percent on day one, then 2, 5, 10, 20, 50 and 100. You can pause it for up to 30 days in total, or release to everyone with one button. Here is exactly what Apple says it does, what it does not do, and how I decide when an Expo app update should use it.

David 8 min
Read article
ExpoClaude Code

How to Add Haptic Feedback to Your Expo App

How to add haptic feedback to your Expo app: install expo-haptics, then call the right method for the moment - selectionAsync for pickers, impactAsync for taps and gestures, notificationAsync for outcomes. Here is the exact mapping, the reason the simulator stays silent, and the one rule that keeps haptics from feeling cheap.

David 8 min
Read article

Ready to build it yourself?

Join App Store Launch Club, the #1 community for building and launching apps, for $9/month.

← Back to the blog