Monitoring Laravel Apps with Nightwatch
I run about ten Laravel projects. Some handle payments, some process faxes, some are simple blogs. All of them need monitoring. After trying Sentry, Flare, and Bugsnag over the years, I landed on Nightwatch — Laravel's first-party monitoring service. Here's why it stuck.
What Nightwatch actually monitors
Nightwatch goes beyond exception tracking. Out of the box, it watches for:
- Exceptions — with full stack traces, request context, and occurrence counts
- Slow routes — any request exceeding a configurable threshold
- Slow jobs — queued jobs that take longer than expected
- Slow commands — artisan commands dragging their feet
- Slow scheduled tasks — scheduled tasks that miss their expected duration
This is the key difference from tools like Sentry. Exception tracking is table stakes. Knowing that your /api/invoices endpoint started taking 3 seconds last Tuesday — without anyone reporting it — is where monitoring earns its keep.
Installation takes two minutes
Install the package and add your project token. That's it.
composer require laravel/nightwatch
Add your token to .env:
NIGHTWATCH_TOKEN=your-project-token
No config files to publish, no middleware to register, no service provider to add. Nightwatch hooks into Laravel's event system automatically. Deploy, and data starts flowing.
The dashboard
Nightwatch's dashboard at nightwatch.laravel.com groups issues by type and shows when they were first seen, last seen, and how often they occur. You can filter by environment, which matters when you run staging and production side by side. Each issue links to a detailed view with the full stack trace, request data, and a timeline of occurrences.
What I like about it
Zero configuration. I've wasted hours configuring Sentry DSNs, setting up release tracking, and debugging why breadcrumbs weren't showing. Nightwatch just works out of the box because it's built for Laravel specifically.
Performance monitoring included. Slow route detection alone has caught two production issues for me that would've gone unnoticed — a missing database index and an N+1 query that only appeared with real data volumes.
MCP integration. Nightwatch ships an MCP server that plugs into Claude Code. I can ask "check Nightwatch for open issues" and get a summary without opening a browser. When debugging, I can pull stack traces directly into my editor context.
Per-project, not per-seat pricing. I pay per application, not per team member. For a solo developer running multiple projects, this makes the cost reasonable.
What I wish was different
- No custom alerting rules yet. You get notified on new issues, but you can't set up rules like "alert me if this endpoint exceeds 500ms more than 10 times in an hour."
- No Slack integration. Notifications go through email. I'd prefer a Discord or Slack webhook.
- Dashboard is still young. The UI is functional but minimal compared to Sentry's polished experience. It's improving fast though.
None of these are dealbreakers. The core monitoring is solid, and the Laravel-native integration makes up for the missing bells and whistles.
My setup across projects
I keep each project's Nightwatch application ID in its CLAUDE.md file. This way, when I'm working in a project and ask Claude to check for issues, it knows which application to query without me specifying it. The MCP server handles the rest.
# In each project's CLAUDE.md
- **Error Tracking**: Nightwatch (App ID: `a11c277e-6f20-41d9-b96a-30bb01eacb0f`)
For dependency updates, I run a script that updates all projects in parallel, runs tests, and commits. If a dependency update introduces a regression, Nightwatch catches it in production and I see it in my next check.
Should you switch?
If you're running Laravel and want monitoring that understands your framework — not a generic APM tool that happens to support PHP — Nightwatch is worth trying. The two-minute setup means there's no reason not to run it alongside your current tool for a week and compare.