Skip to content
pubscout

sentry

10.6.0, released today by sentry.io

Crash reporting and error tracking library for Dart and Flutter applications.

Flutter FavoriteWASM-readyRock solid
$ flutter pub add sentry
Source repository

What it does

A crash reporting and error-tracking library that sends exceptions, stack traces, and performance monitoring metrics to Sentry.io. It supports Dart VM and Web, offering features like HTTP request breadcrumbs and error capture.

AI-written summary of version 10.3.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to capture and report runtime crashes or exceptions to a centralized dashboard.
  • You want to track HTTP request performance and catch failed network requests as errors.

Skip it when

  • You are using Flutter and should instead use the dedicated `sentry_flutter` package for full native crash support.
  • You do not use Sentry.io as your error tracking backend.

Strengths

  • Comprehensive error capture including unhandled exceptions and HTTP requests.
  • Supports both Dart VM and Web platforms.
  • Easy integration with `Sentry.init` or custom error zones.

Weaknesses

  • For Flutter applications, this base package lacks some native features provided by `sentry_flutter`.
  • Requires an external Sentry.io account and DSN setup.

Setup

Kind
FFI (native library)
Effort
Low
Code generation
No
Direct dependencies
6

Sign up for a Sentry.io account to obtain a DSN, add the dependency, and initialize the SDK in your main function.

import 'package:sentry/sentry.dart';

Future<void> main() async {
  await Sentry.init(
    (options) {
      options.dsn = 'https://example@sentry.io/example';
    },
    appRunner: initApp,
  );
}

void initApp() {
  // your app code
}

Alternatives

Packages that do the same job and could replace sentry.

Works with

Packages commonly used together with sentry: ones it builds on, ones built on it, and its own family.