---
title: "Console logging"
description: "Capture console API calls as Sentry logs in React Native."
url: https://docs.sentry.io/platforms/react-native/integrations/console-logging/
---

# Console logging | Sentry for React Native

##### Sentry Logs

Enable the Sentry Logs feature with `enableLogs: true` in your `Sentry.init` call to unlock Sentry's full logging power. With Sentry Logs, you can search, filter, and analyze logs from across your entire application in one place.

Console Logging integration is enabled by default which means calls to the `console` API will be captured as logs in Sentry. By default the integration instruments `console.debug`, `console.info`, `console.warn`, `console.error`, `console.log`, `console.trace`, and `console.assert`.

## [Disabling Console Logging Integration](https://docs.sentry.io/platforms/react-native/integrations/console-logging.md#disabling-console-logging-integration)

To disable the integration, filter it out from the integrations array:

```js
Sentry.init({
  ...,
  integrations(integrations) {
    return integrations.filter(i => i.name !== 'ConsoleLogs');
  },
  ...
})
```

You can also filter out the automatically captured logs in `beforeSendLog`:

```js
Sentry.init({
  ...,
  beforeSendLog: (log) => {
    if (log.attributes?.['sentry.origin'] === 'auto.log.console') {
      return null;
    }
    return log;
  },
  ...
})
```
