Back to blog
Tutorials

Uptime Monitoring for Vercel: What Works, What Doesn't, and How to Set It Up

Vercel doesn't include uptime monitoring. Here's how to monitor your Vercel deployments, edge functions, and API routes properly - including what to check and what common tools miss.

Vantaj Team · June 24, 2026 · 10 min read

Vercel is excellent at deploying and hosting Next.js applications. It handles global CDN distribution, serverless function scaling, edge caching, and preview deployments with almost no configuration.

What Vercel doesn't include: uptime monitoring.

If your production app on Vercel goes down - due to a serverless function error, an edge middleware crash, an upstream database failure, or a Vercel platform incident - you won't know until a user reports it or you happen to open your dashboard.

This guide covers how to set up meaningful uptime monitoring for Vercel deployments, what to actually monitor (it's more than just the homepage), and what most monitoring tools miss about serverless architectures.

What "Down" Means on Vercel

On a traditional server, "down" is simple: the server isn't responding. On Vercel, there are several distinct failure modes:

Failure typeWhat happensDetectable by HTTP monitoring?
Vercel platform outageAll requests fail or time out✅ Yes
Serverless function crashFunction returns 500 error✅ Yes (if you monitor the right endpoint)
Edge middleware errorRequests hang or return 500 before reaching your app✅ Yes
Build/deployment failureNew deployments fail silently, traffic routes to last working build❌ No (not detectable by HTTP monitoring alone)
Database connection failureAPI routes that need DB return 500, static pages still load fine✅ Only if you monitor API routes specifically
Third-party API dependency failureYour code returns 500 for affected features✅ Only if you test the specific affected endpoint
Edge cache serving stale contentThe site "works" but serves outdated data❌ Requires content validation, not just HTTP checks

The implication: monitoring https://yourapp.com with an HTTP check tells you if the homepage loads. It tells you almost nothing about whether your API routes, authentication, checkout flow, or database-dependent features are functioning.

What to Actually Monitor on Vercel

1. A health check endpoint (not the homepage)

Create a dedicated /api/health route in your Next.js app that actually tests your dependencies:

// app/api/health/route.ts
import { db } from '@/lib/db'

export async function GET() {
  try {
    // Test your actual database connection
    await db.execute('SELECT 1')

    return Response.json({
      status: 'ok',
      timestamp: new Date().toISOString(),
      checks: {
        database: 'ok',
      }
    })
  } catch (error) {
    return Response.json(
      {
        status: 'error',
        error: 'Database connection failed',
      },
      { status: 503 }
    )
  }
}

Monitor this endpoint, not the homepage. The homepage can return 200 even when your database is completely unreachable - it might just serve cached static content while your users get errors on every page that requires data.

2. Your most critical user-facing API routes

For a SaaS app, this typically means:

  • Authentication endpoint (/api/auth/session or similar)
  • Your most-used data fetch endpoint
  • Any payment-critical routes

A 500 on /api/auth means nobody can log in. A 500 on /api/checkout means you're losing revenue. Your homepage might still be perfectly green.

3. Critical serverless functions

If you use Vercel serverless functions for background processing, webhooks, or data pipelines, monitor those endpoints directly. A function crash won't affect the frontend but can silently break your entire data layer.

4. Edge middleware, if you use it

If you have Vercel Edge Middleware (for auth, redirects, A/B testing, or geolocation), it runs before your pages and API routes. A middleware error can take down the entire application silently. Add a test path that goes through middleware:

// middleware.ts
export function middleware(request: NextRequest) {
  // If this path is /api/health, skip middleware
  if (request.nextUrl.pathname === '/api/health') {
    return NextResponse.next()
  }
  // ... your actual middleware logic
}

Then monitor a path that does exercise middleware (like a protected route that should redirect) and confirm the expected response code.


Setting Up Monitoring for Vercel with Vantaj

Step 1: Create your health check endpoint

Add the /api/health route from above to your Next.js project.

Step 2: Add monitors

In Vantaj, add the following monitors:

Monitor 1: Health Check
URL: https://yourapp.com/api/health
Type: HTTP
Expected status: 200
Interval: 1 minute

Monitor 2: Authentication
URL: https://yourapp.com/api/auth/session
Type: HTTP
Expected status: 200 or 401 (both mean the route is working)
Interval: 1 minute

Monitor 3: Homepage (static)
URL: https://yourapp.com
Type: HTTP
Expected status: 200
Interval: 5 minutes

Monitor 4: SSL Certificate
URL: https://yourapp.com
Type: SSL
Alert: 30 days before expiry

Step 3: Configure multi-region checks

Vercel serves traffic from edge locations globally. Set up your monitoring to check from multiple regions to distinguish between:

  • Global outage: All regions see failure → your app is actually down
  • Vercel edge node issue: One region sees failure, others pass → regional CDN issue

With Vantaj's multi-region consensus, this happens automatically - an alert only fires when multiple independent probe locations confirm the failure. This prevents false positives from transient Vercel edge node issues.

Step 4: Set up status page

Optionally, create a public status page showing the health of your application. Link it from your app's footer and help documentation so customers know where to check during outages.


Common Mistakes When Monitoring Vercel Apps

Monitoring only the homepage

The most common mistake. A static homepage served from Vercel's CDN can return 200 while every serverless function in your app is crashing. Always include at least one API route that exercises your database or critical backend logic.

Monitoring the vercel.app preview URL instead of production

Preview deployments have different URLs. Monitor your production domain, not the default Vercel URL.

Not handling cold starts in alerting

Vercel serverless functions have cold starts - the first request after a period of inactivity can take 1–3 seconds longer than warm requests. Some monitoring tools treat cold start latency spikes as outages.

The fix: use a timeout threshold that accounts for cold starts (3–5 seconds rather than the default 1–2 seconds), and rely on HTTP status codes (500/503) rather than latency alone to determine "down" vs "slow."

Missing the Vercel Platform status

Monitor your own app, but also know when Vercel itself has issues. Subscribe to Vercel's status page updates. When Vercel has a platform incident, every app deployed there is affected - including yours. Your monitoring will detect it through your endpoint, but having Vercel's status page in your feed helps you quickly distinguish "my code is broken" from "Vercel is having issues."

No SSL monitoring

Vercel handles SSL certificate provisioning automatically, but auto-renewal can fail. Monitor your SSL certificate expiry and set up alerts for 30+ days before expiry. A failed renewal is rare but catastrophic - your entire site goes red in browsers with no warning.


Vercel-Specific Configuration Tips

Caching behavior and health checks

Vercel caches aggressively. Make sure your health check endpoint is not cached:

// app/api/health/route.ts
export const dynamic = 'force-dynamic' // Prevent caching
export const revalidate = 0

export async function GET() {
  // ... health check logic
}

If your health endpoint is cached, monitoring will always return 200 even during an outage.

Serverless function timeouts

Vercel has a default serverless function timeout of 10 seconds (configurable to 30s on Pro, 900s on Enterprise). If your health check depends on a slow database query, it might time out under load and return a 504 to your monitoring. Set your monitoring timeout to 8–9 seconds for health endpoints to catch these before Vercel's own timeout kicks in.

Environment variables and deployment failures

If a deployment fails to load environment variables correctly, your serverless functions will crash on startup. A health check that tests database connectivity (SELECT 1) will immediately surface this - the function will return 500 or crash with a missing environment variable error.

This is one of the most common causes of "site went down after a deploy" incidents on Vercel.


Monitoring Next.js App Router vs Pages Router

Both work fine with standard HTTP monitoring, but there are differences in how you write health checks:

Pages Router (pages/api/health.ts):

import type { NextApiRequest, NextApiResponse } from 'next'

export default async function handler(req: NextApiRequest, res: NextApiResponse) {
  res.setHeader('Cache-Control', 'no-store')

  try {
    // test your database
    res.status(200).json({ status: 'ok' })
  } catch (e) {
    res.status(503).json({ status: 'error' })
  }
}

App Router (app/api/health/route.ts):

export const dynamic = 'force-dynamic'

export async function GET() {
  try {
    // test your database
    return Response.json({ status: 'ok' })
  } catch (e) {
    return Response.json({ status: 'error' }, { status: 503 })
  }
}

What Good Vercel Monitoring Looks Like

After setup, you should have:

MonitorPurposeAlert on
/api/healthTests database + app layerNon-200 status or >5s response
/api/auth/sessionTests auth layerNon-200/401 status
HomepageTests CDN deliveryNon-200 status
SSL certificateTests cert validity30 days before expiry
Domain expiryTests domain registration60 days before expiry

With these five monitors, you'll catch:

  • Vercel platform outages
  • Serverless function crashes
  • Database connection failures
  • Authentication layer failures
  • SSL/domain renewal failures

What you won't catch with HTTP monitoring alone:

  • Build failures (monitor your CI/CD logs separately)
  • Edge cache serving stale content (requires content validation)
  • Performance regressions (requires APM, not uptime monitoring)

Quick Setup

If you want to get this running today:

  1. Add a /api/health endpoint to your Next.js app (code above)
  2. Deploy to Vercel
  3. Start monitoring at app.vantaj.co - free tier includes 20 monitors, multi-region consensus, and SSL monitoring
  4. Add the 4–5 monitors described above
  5. Configure Slack or email alerts

The whole setup takes about 10 minutes and gives you coverage for the failure modes that actually take down Vercel-hosted production apps.