How do I report an error that my code already caught?

Call Sentry.captureException(error) in the catch block, then handle the error as you planned. Monitoring groups it into an issue like any other error, keeps its stack and breadcrumbs, and emails Owners and Administrators the first time it appears. A caught error is not marked Unhandled, so you can tell it apart from a crash.

Last updated 26 November 2026. By Paul Badarau.

Sam, a fictional developer, runs a newsletter sign-up form. When the subscribe request fails, the code catches the error and shows "Try again". Visitors see a polite message, and Sam sees nothing, because a caught error never reaches the SDK's global handlers. One line in the catch block changes that:

try { await subscribe(email); } catch (error) { Sentry.captureException(error); showRetryMessage(); }

Use these rules to decide what to report and how:

  1. Report failures you recover from but should not happen, such as a save or a payment call that throws.
  2. Leave out outcomes you expect, such as a form field that fails validation. Each one would be an event, and a log line or nothing at all fits them better.
  3. Pass the error object itself. Its stack decides the issue it joins and shows where it failed.
  4. Add what you know at that point as tags: Sentry.captureException(error, { tags: { step: 'subscribe' } }). Monitoring keeps up to 30 tags per event.
  5. For a problem without an exception, send a message with a level: Sentry.captureMessage('Rate service returned no rate', 'warning'). Messages group by level and text, with numbers and IDs removed.

On the issue page, an error the SDK caught by itself carries an Unhandled badge, and one you reported from a catch block does not. Both group by the same rules, so the same bug caught in one place and crashing in another joins one issue.

Watch for catch blocks inside a retry loop. If the request is tried three times, a report in the catch sends three events for one failure. Each event counts toward the 10,000 Monitoring events a month that errors and log lines share across the Workspace. Report once, after the last attempt fails.

The product page for this is Monitoring.

Start your 14-day free trial