$0 while in beta!
Fix errors directly in your editor with our MCP server for seamless ai-development workflow.
Get tailored code fixes and root‑cause insights generated from your own stack.
Only the error data you need — so you can focus on fixing, not filtering.
Lightweight Next.js client that won't slow down your users.
Initialize Better Errors in your app with your project URL:
Add automatic error capturing by creating an instrumentation file in your Next.js project:
For client-side error capturing, create a matching instrumentation file:
To enable source map uploading for better stack traces, wrap your Next.js configuration with withBetterErrorsConfig
:
Ensure you have experimental.serverSourceMaps
and productionBrowserSourceMaps
enabled in your main Next.js configuration. The apiKey
is required for uploading source maps. You can set this using the BETTER_ERRORS_API_KEY
environment variable. On platforms like Vercel, simply add this environment variable to your project settings.
Capture errors in event handlers or try/catch blocks:
Better Errors integrates with your favorite code editors through our MCP server, allowing you to fix bugs without leaving your development environment.
Jump directly from error notifications to the exact line of code that needs fixing.
Apply suggested fixes with a single click or customize them to your codebase's patterns.