DEV.co
Open-Source DevOps · spatie

laravel-server-monitor

laravel-server-monitor is a PHP package for Laravel that automatically monitors server health by checking disk space, memory, process status, and other critical metrics. It sends alerts via Slack or email when problems are detected, helping prevent unexpected downtime.

Source: GitHub — github.com/spatie/laravel-server-monitor
844
GitHub stars
95
Forks
PHP
Primary language
MIT
License (OSI-approved)

Key facts

Objective fields from the source. Values we can't verify are shown as “Unknown” rather than guessed.

FieldValue
Repositoryspatie/laravel-server-monitor
Ownerspatie
Primary languagePHP
LicenseMIT — OSI-approved
Stars844
Forks95
Open issues0
Latest release1.10.2 (2026-02-21)
Last updated2026-02-21
Sourcehttps://github.com/spatie/laravel-server-monitor

What laravel-server-monitor is

A Laravel package that executes remote SSH checks on monitored hosts against configurable thresholds, storing results in a local database and dispatching notifications through mail/Slack channels. It provides built-in checks for diskspace, Elasticsearch, Memcached, and MySQL, with extensibility via custom CheckDefinition classes.

Quickstart

Get the laravel-server-monitor source

Clone the repository and explore it locally.

terminalbash
git clone https://github.com/spatie/laravel-server-monitor.gitcd laravel-server-monitor# follow the project's README for install & configuration

Need it deployed, integrated, or customized instead? DEV.co ships production installs.

Best use cases

Multi-server infrastructure monitoring

Track health across multiple production servers from a single Laravel application, with centralized alerting to prevent cascading failures from unnoticed resource exhaustion.

Proactive capacity management

Configure warning and failure thresholds (e.g., disk 80%/90%) to catch resource constraints before they cause outages, enabling planned scaling or cleanup.

Laravel-native ops integration

For Laravel shops already running Laravel dashboards or Nova installations, embed server monitoring directly into existing infrastructure without adding separate tools.

Implementation considerations

  • Requires SSH access to monitored hosts with appropriate credentials configured; ensure key exchange and host verification are properly set up before deploying.
  • Concurrent SSH connection limit defaults to 5; adjust based on host count and server capacity to avoid connection exhaustion or timeouts.
  • Built-in checks are limited (diskspace, Elasticsearch, Memcached, MySQL); custom checks require extending CheckDefinition class and thorough testing.
  • Database migrations must be run; ensure Laravel app has schema access and migrations are version-controlled and deployed before package activation.
  • Notification throttling (60 min default) prevents alert fatigue but may delay awareness of repeated failures; tune based on ops SLA.

When to avoid it — and what to weigh

  • Requires comprehensive monitoring dashboard UI — This package provides only backend monitoring logic and database storage; no built-in web UI. You must build custom views, use Laravel Nova with third-party extensions, or integrate with external dashboards.
  • Enterprise-scale monitoring needs — No native clustering, horizontal scaling, or high-availability features. Designed for smaller deployments; large-scale ops likely need Prometheus, Datadog, or New Relic.
  • Non-Laravel environments — Tightly coupled to Laravel framework and service providers; cannot be used standalone in non-Laravel PHP applications or other tech stacks.
  • Real-time metrics and time-series data — Focuses on threshold-based checks rather than continuous telemetry collection, graphing, or performance trend analysis. Not suitable for detailed performance profiling.

License & commercial use

MIT License. Permissive OSI-approved license allowing commercial use, modification, and distribution with attribution and no warranty.

MIT License explicitly permits commercial use without restriction. No proprietary features, license agreements, or vendor lock-in detected. Safe for commercial deployments subject to standard MIT terms (attribution, no liability).

DEV.co evaluation signals

Editorial assessment — not user reviews. Directional, with an explicit confidence level.

SignalAssessment
MaintenanceActive
DocumentationStrong
License clarityClear
Deployment complexityLow
DEV.co fitGood
Assessment confidenceHigh
Security considerations

SSH private keys must be securely stored (env vars, secrets manager, not hardcoded). Package executes remote commands; validate or restrict custom check implementations to prevent command injection. Notification webhooks (Slack) should use HTTPS; protect webhook URLs from exposure. No explicit security audit details provided; review process_manipulator if using custom logic. Report security issues to [email protected] per README guidance.

Alternatives to consider

Prometheus + Grafana

Industry-standard time-series monitoring with rich dashboarding, querying, and alerting. Requires more infrastructure but scales to enterprise deployments.

Datadog

SaaS monitoring platform with APM, infrastructure monitoring, logs, and dashboards. Vendor-managed infrastructure and higher cost but minimal ops overhead.

Laravel Horizon + Telescope

Laravel-native tools for queue job and application performance monitoring. Limited to application-level insights; does not cover host-level infrastructure checks.

Software development agency

Build on laravel-server-monitor with DEV.co software developers

laravel-server-monitor is lightweight, actively maintained, and MIT-licensed. Start with Composer, configure SSH, and set up notifications. Contact Devco for custom check development or infrastructure guidance.

Talk to DEV.co

Related open-source tools

Surfaced by semantic similarity across the DEV.co open-source index.

Related on DEV.co

Explore the category and the services that help you build with it.

laravel-server-monitor FAQ

Can I use this without Laravel?
No. The package is tightly coupled to Laravel's service provider, config, and model systems. It requires a working Laravel application.
Does this include a web dashboard?
Not out of the box. You must build custom views or use the third-party Laravel Nova package (nova-server-monitor by insenseanalytics) for UI.
What if a host is unreachable?
Not clearly stated in the documentation excerpt. Requires review of source code or full documentation to confirm retry logic and failure handling.
Can I add custom health checks?
Yes. Extend the CheckDefinition class and register it in the config 'checks' array. Examples and guidance are in the documentation.

Software development & web development with DEV.co

DEV.co helps companies turn open-source tools like laravel-server-monitor into production software. Our software development services cover the full lifecycle — architecture, web development, integration, and maintenance — delivered by software developers and web developers who ship. Engage our software development agency to implement or customize it for your open-source devops stack.

Need server monitoring integrated with Laravel?

laravel-server-monitor is lightweight, actively maintained, and MIT-licensed. Start with Composer, configure SSH, and set up notifications. Contact Devco for custom check development or infrastructure guidance.