React Error Handling

Errors happen.
Get notified.

Wrap your React components and functions. When errors occur, we'll send you an email. That's it.

Configuration
import { 
configureErrorReporting, 
ErrorBoundary, 
} from 'errormail';

configureErrorReporting({
  apiKey: 'your-api-key',
  emailTo: 'admin@example.com'
})

<ErrorBoundary>
  <MyComponent />
</ErrorBoundary>
Email Preview

See what you'll receive

Every error is automatically formatted into a beautiful, detailed email report

mail.example.com • Error Report
ErrorMail
Error Report
Error

Error Detected

12/17/2025, 9:12:01 PM

Error Message
Failed to fetch user data
Error Type
TypeError
Function
fetchUserData
Breadcrumbs (3)
User clicked checkout buttonui
9:11:31 PM
Navigate to /checkoutnavigation
9:11:36 PM
GET /api/carthttp
9:11:41 PM
Environment
BrowserChrome 120
OSmacOS
URLexample.com/checkout
Stack Trace
TypeError: Failed to fetch
at fetchUserData (app.js:45)
at handleCheckout (checkout.js:12)

This error was automatically reported by ErrorMail

Wrap Functions

Wrap any async or sync function. Errors are caught and emailed automatically.

Email Reports

Get detailed error reports in your inbox with stack traces and context.

Breadcrumbs

Track user actions leading up to errors for better debugging context.

Severity Levels

Categorize errors as debug, info, warning, error, or fatal.

Environment Info

Automatic browser, device, and runtime information capture.

Rate Limiting

Prevent duplicate error flooding with automatic deduplication.

Quick Start Guide

Get set up in just a few clicks

bun add errormail

Then Get Your API key by signing in and creating a api key

And you're all done. Checkout our Documentation to keep up to date