Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
title: Out-of-Process Native Crash Handling
description: "Learn how to send native crash reports from a separate process on Android."
sidebar_order: 90
---

On Android, the React Native SDK uses [Sentry Native](/platforms/native/) through the [Android SDK's NDK integration](/platforms/android/configuration/using-ndk/) to capture native crashes. By default, it uses Sentry Native's `inproc` backend, which handles crashes inside the crashed application and sends the crash reports on the next launch of the application.

Alternatively, you can enable [out-of-process crash handling](/platforms/android/configuration/using-ndk/#out-of-process-crash-handling). A crash service then handles crashes outside the crashed application and sends the crash reports at crash time, instead of on the next launch.

<Alert title="Experimental">

Out-of-process crash handling is experimental.

</Alert>

## Configuration

Set `SENTRY_NATIVE_BACKEND` to `native` in `android/gradle.properties`, or as an environment variable in your local build environment and CI, before building the application:

```properties {filename:android/gradle.properties}
SENTRY_NATIVE_BACKEND=native
```

This is a build-time setting, not a JavaScript SDK initialization option.

The crash service runs in a separate process, where Android creates a second instance of your `Application` class. See [Second Application Instance](/platforms/android/configuration/using-ndk/#second-application-instance).
Loading