tutorial

Monitoring Fluffychat with Vigilmon

Fluffychat is a friendly Matrix client you can self-host on the web — but its Flutter build, Matrix sync stream, and push gateway all need watching. Here's how to monitor every layer with Vigilmon.

Fluffychat is a cross-platform Matrix chat client built with Flutter/Dart, with a reputation for simplicity and a welcoming UI. When self-hosted as a web application behind nginx or Caddy, it combines a static Flutter web build with a live WebSocket connection to a Matrix homeserver and an optional push gateway for notifications. Vigilmon lets you monitor all three layers so you catch failures before your users notice their messages aren't arriving.

What You'll Set Up

  • Web server availability and TLS certificate expiry alerts
  • Static Flutter web build serving latency
  • Matrix homeserver API connectivity
  • WebSocket upgrade path health (Matrix sync stream)
  • Push gateway service reachability
  • CORS configuration for the web deployment
  • Web app manifest and service worker integrity checks

Prerequisites

  • Fluffychat web build deployed and accessible at a public or internal HTTPS URL
  • nginx or Caddy serving the Flutter build
  • Your Matrix homeserver URL (e.g. https://matrix.yourdomain.com)
  • (Optional) UnifiedPush or Matrix push notification relay URL
  • A free Vigilmon account

Step 1: Monitor Web Server Availability and TLS

Fluffychat's web app is useless if the web server is down or the TLS certificate is expired. Add a single monitor that catches both:

  1. Log in to vigilmon.online and click Add Monitor.
  2. Set Type to HTTP / HTTPS.
  3. Enter your Fluffychat URL: https://fluffychat.yourdomain.com.
  4. Set Check interval to 1 minute.
  5. Set Expected HTTP status to 200.
  6. Enable Monitor SSL certificate.
  7. Set Alert when certificate expires in less than 21 days.
  8. Click Save.

A 21-day SSL alert window is wide enough to catch Let's Encrypt renewal failures before they cascade into browser warnings.


Step 2: Monitor Static Flutter Web Build Serving Latency

Flutter web builds are large — the compiled Dart-to-JavaScript output can be several megabytes. Slow serving causes the app to hang on the splash screen, which users interpret as the app being broken. Add a keyword monitor that validates the build is being served correctly:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter: https://fluffychat.yourdomain.com/index.html.
  3. Set Keyword must be present to FluffyChat (matches the page title in the Flutter build's index.html).
  4. Set Check interval to 5 minutes.
  5. Enable Response time alert.
  6. Set Alert if response time exceeds 3000 ms.
  7. Click Save.

Also monitor the Flutter main wasm or JS entry point to catch missing build artifacts:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter: https://fluffychat.yourdomain.com/flutter.js.
  3. Set Expected HTTP status to 200.
  4. Set Check interval to 5 minutes.

Step 3: Monitor Matrix Homeserver API Connectivity

Fluffychat cannot function without a reachable Matrix homeserver. Even if the Fluffychat web app loads perfectly, users will see a login failure if the homeserver is unreachable. Monitor the homeserver's client-server API:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter: https://matrix.yourdomain.com/.well-known/matrix/client.
  3. Set Expected HTTP status to 200.
  4. Set Keyword must be present to m.homeserver.
  5. Set Check interval to 1 minute.
  6. Click Save.

Also add a monitor for the versioned API endpoint:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter: https://matrix.yourdomain.com/_matrix/client/versions.
  3. Set Expected HTTP status to 200.
  4. Set Keyword must be present to versions.
  5. Set Check interval to 1 minute.

Step 4: Monitor WebSocket Upgrade Path Health

Fluffychat relies on the Matrix /sync long-polling stream to receive messages in real time. This goes through your nginx or Caddy reverse proxy — and proxy WebSocket configuration mistakes (missing Upgrade headers, short proxy timeouts) break the sync stream silently. Test that the upgrade path is configured correctly:

Verify your nginx config includes the required WebSocket proxy headers for the Matrix homeserver location block:

location /_matrix/ {
    proxy_pass http://localhost:8008;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "upgrade";
    proxy_set_header Host $host;
    proxy_read_timeout 600s;
}

Then add a monitor that probes the sync endpoint with a short timeout — a 401 response confirms the WebSocket upgrade path is being reached:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter: https://matrix.yourdomain.com/_matrix/client/v3/sync?timeout=0.
  3. Set Expected HTTP status to 401 (unauthenticated probe — valid response proves the endpoint is reachable).
  4. Set Check interval to 2 minutes.
  5. Enable Response time alert with a threshold of 5000 ms.
  6. Click Save.

A timeout or 502 Bad Gateway here signals that your proxy is not forwarding requests to the homeserver correctly.


Step 5: Monitor Push Gateway Reachability

If you've configured UnifiedPush or a Matrix push notification gateway, a down push service means users stop receiving notifications on mobile — a failure mode that's easy to miss because the web app itself still works. Add a reachability check:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter your push gateway's health or root URL: https://push.yourdomain.com/_matrix/push/v1/notify (UnifiedPush relay endpoint — returns 405 Method Not Allowed on a GET, which is still a live response).
  3. Set Expected HTTP status to 405.
  4. Set Check interval to 5 minutes.
  5. Click Save.

If your push gateway exposes a dedicated health endpoint, use that instead. Adjust the expected status code to match.


Step 6: Verify Web App Manifest and Service Worker Integrity

Fluffychat's web app uses a service worker for offline caching and push notifications. A missing or malformed manifest breaks Progressive Web App (PWA) installation and push notification delivery. Add monitors for both:

Web app manifest:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter: https://fluffychat.yourdomain.com/manifest.json.
  3. Set Expected HTTP status to 200.
  4. Set Keyword must be present to fluffychat (matches the app name in the manifest).
  5. Set Check interval to 10 minutes.

Service worker:

  1. Click Add MonitorHTTP / HTTPS.
  2. Enter: https://fluffychat.yourdomain.com/flutter_service_worker.js.
  3. Set Expected HTTP status to 200.
  4. Set Check interval to 10 minutes.

Step 7: Monitor Matrix /sync Endpoint Response Times

Even when the sync endpoint is reachable, slow response times mean messages arrive late and typing indicators lag. Track API latency separately to catch homeserver performance degradation before it becomes an outage:

  1. Open the /_matrix/client/versions monitor from Step 3.
  2. Enable Response time alert.
  3. Set Alert if response time exceeds 2000 ms.
  4. Click Save.

Set a longer threshold on the sync endpoint monitor (Step 4) since the ?timeout=0 probe still involves a database lookup on the homeserver — 5000 ms is a reasonable alert threshold for that endpoint under load.


Step 8: Configure Alert Channels

  1. Go to Alert Channels in Vigilmon and add Slack, email, Discord, or a webhook.
  2. For the web server and TLS monitor (Step 1), set Consecutive failures before alert to 2 — a brief web server restart should not wake you up at 3 AM.
  3. For homeserver monitors (Steps 3–4), set Consecutive failures before alert to 1 — every Fluffychat user is affected immediately.
  4. For push gateway and manifest monitors (Steps 5–6), set Consecutive failures before alert to 3 — these services are less latency-sensitive.
  5. Use Maintenance windows in Vigilmon when upgrading Fluffychat or the homeserver.

Conclusion

A self-hosted Fluffychat deployment has three failure domains: the static web serving layer, the Matrix homeserver API, and the push/notification pipeline. Here's the full coverage summary:

| Layer | Monitor | |---|---| | Web server | HTTP uptime on https://fluffychat.yourdomain.com | | TLS certificate | SSL expiry alert (21-day window) | | Flutter build | Keyword check on index.html + response time | | Matrix API | /.well-known/matrix/client + /versions | | WebSocket/sync | /_matrix/client/v3/sync?timeout=0 | | Push gateway | UnifiedPush relay endpoint availability | | PWA manifest | manifest.json keyword check | | Service worker | flutter_service_worker.js availability |

With these monitors active, you'll know about a homeserver failure within a minute — long before users start asking why their messages stopped appearing.

Monitor your app with Vigilmon

Free plan — 5 monitors, no credit card required. Up and running in 60 seconds.

Start free →