Vercel's Hobby plan keeps about one hour of runtime logs. FlareLog records every server error from Server Components, Server Actions and Route Handlers, plus client crashes, and keeps them searchable for 7 to 90 days.
Free up to 25,000 logs/mo · no card needed
Application error: a server-side exception has occurred
Digest: 2948302219...
Logs expired
Hobby keeps about 1 hour of runtime logs
Your Next.js app is production-grade. But your logs aren't. By morning the trace is gone.
In production, Next.js replaces server errors with a digest. The real stack trace is in the host's logs, and on Vercel Hobby those are gone after about an hour. FlareLog stores the digest next to the error, so you can paste it in and find the failure.
Next.js calls onRequestError in instrumentation.ts for every uncaught server error. FlareLog plugs into that hook, so there is nothing to wrap.
Install the SDK
Run npm install @flarelog/sdk. One package covers the server, Route Handlers and React client errors.
Set your API key
Add FLARELOG_API_KEY to your Vercel environment variables or .env.local.
Add instrumentation.ts
Export onRequestError from createOnRequestError. Server Component, Server Action, Route Handler and middleware errors are now captured with their digest.
Add context where you need it (optional)
Wrap a Route Handler with withNextRouteHandler for request logs and traces, and add FlareLogErrorBoundary in a client provider for browser errors. On the Pages Router, use withFlareLog.
import { flarelog } from "@flarelog/sdk";
import { createOnRequestError } from "@flarelog/sdk/next";
const logger = flarelog({ apiKey: process.env.FLARELOG_API_KEY });
// Every uncaught server error: Server Components, Server Actions,
// Route Handlers and middleware. The digest from the error page
// is stored with the stack trace, so you can search for it.
export const onRequestError = createOnRequestError(logger);import { flarelog } from "@flarelog/sdk";
import { withNextRouteHandler } from "@flarelog/sdk/next";
const logger = flarelog({ apiKey: process.env.FLARELOG_API_KEY });
export const POST = withNextRouteHandler(logger, async (request) => {
const body = await request.json();
logger.info("Checkout started", { cartId: body.cartId });
const order = await createOrder(body);
logger.info("Order created", { orderId: order.id });
return Response.json({ order });
});"use client";
import { flarelog } from "@flarelog/sdk";
import { FlareLogErrorBoundary } from "@flarelog/sdk/react";
const logger = flarelog({
apiKey: process.env.NEXT_PUBLIC_FLARELOG_API_KEY,
});
export function Providers({ children }) {
return (
<FlareLogErrorBoundary logger={logger}>
{children}
</FlareLogErrorBoundary>
);
}# Add to your Vercel project
vercel env add FLARELOG_API_KEY
# or paste in the dashboard
FLARELOG_API_KEY=fl_your_api_keyStop losing incident context after one hour. FlareLog keeps 7 days on the free tier and 90 days on Pro, so last week's failing Server Action is still searchable.
Search structured logs by route path, digest, error message, or any field you log. Each error keeps the route type (render, action, route or middleware) that Next.js reports.
Background work inside Server Actions, Route Handlers, or waitUntil is flushed before the invocation ends, so it isn't lost when the function freezes.
Vercel's event-based observability metering scales with every request. FlareLog Pro is a flat $19/mo for up to 1M logs, so bot traffic doesn't turn into a surprise invoice.
Scrapers hitting dynamic routes can generate millions of log events. FlareLog's Pro bucket absorbs the noise without multiplying your bill.
Product Hunt traffic is a good problem until your logging bill grows with it. A flat rate keeps launch day predictable.
A digest string on its own tells you nothing. Search for it in FlareLog to see the stack trace and the context you logged.
FlareLog's MCP server connects Cursor, Claude Desktop, or Lovable Agent to your real Next.js logs. Skip the dashboard and let your AI read structured production errors in context.
{
"mcpServers": {
"flarelog": {
"url": "https://mcp.flarelog.dev",
"headers": {
"Authorization": "Bearer fl_your_api_key"
}
}
}
}Cursor format. Other MCP clients use the same URL and bearer token.
Yes. Add onRequestError to instrumentation.ts to capture every server error, and wrap Route Handlers with withNextRouteHandler for request logs. The Pages Router uses withFlareLog.
No. Logs are batched and sent asynchronously out-of-band. Per-request overhead is sub-millisecond, so your TTFB and action latency stay untouched.
Yes. Server Action failures reach FlareLog through onRequestError with the route path, digest and stack trace, plus anything you log yourself. They are kept for 7 days on Free and 90 days on Pro.
Use FlareLogErrorBoundary and useFlareLog from @flarelog/sdk/react to send React render and caught errors to the same dashboard.
No. FlareLog is independent of your Vercel tier. You can stay on Vercel Hobby and still get days of log retention and structured search.
Free tier includes 25,000 logs/mo and 7-day retention. Pro is $19/mo for 1M logs/mo and 90-day retention. No surprises during traffic spikes.
The free tier includes 25,000 logs a month, structured search and client error capture. No credit card and no marketplace integration. Install the SDK and add one file.