Basic Initialization
The simplest way to initialize Sentry is with just your DSN:Common Configuration Options
Release Tracking
Identify your application version to track regressions and know when issues were introduced:Environment
Differentiate between production, staging, and development environments:Debug Mode
Enable debug logging during development:Default Integrations
The SDK includes default integrations that are automatically enabled:Customizing Integrations
You can add custom integrations or disable default ones:Transport Configuration
By default, the SDK usesmakeFetchTransport. You can customize the transport:
Offline Transport
For applications that need to work offline:Platform-Specific Initialization
Browser (Vanilla JavaScript)
React
Node.js
Next.js
Next.js requires special initialization files. Create these files in your project root: instrumentation.ts (required for Next.js 15+, optional but recommended for 13.2+):Verifying Your Setup
After initialization, test that events are being sent:Next Steps
Environment Configuration
Configure environment-specific settings
Sampling
Control data volume with sampling
Filtering
Filter events before sending to Sentry
Performance Monitoring
Set up performance monitoring