Skip to content
2 min read

Working with Checks

Vercel automatically keeps an eye on various aspects of your web application using the Checks API. Learn how to use Checks in your Vercel workflow here.
Table of Contents
Choose a framework to optimize documentation to:

    Checks are tests and assertions created and run after every successful deployment. Checks API defines your application's quality metrics, runs end-to-end tests, investigates APIs' reliability, and checks your deployment.

    Most testing and CI/CD flows occur in synthetic environments. This leads to false results, overlooked performance degradation, and missed broken connections.

    Flow Type
    Checks 200 responses on specific pages or APIs. Determine the deployment's health and identify issues with code, errors, or broken connections
    Collects core web vital information for specific pages and compares it with the new deployment. It helps you decide whether to build the deployment or block it for further investigation
    Validates that your deployment has all the required components to build successfully. And identifies any broken pages, missing images, or other assets
    Optimizes information about the bundle size. Ensures that your website manages large assets like package and image size
    The depiction of how the Checks lifecycle works.
    The depiction of how the Checks lifecycle works.
    The depiction of how the Checks lifecycle works.

    The diagram shows the complete lifecycle of how a check works:

    1. When a deployment is created, Vercel triggers the deployment.created webhook. This tells integrators that checks can now be registered
    2. Next, an integrator uses the Checks API to create checks defined in the integration configuration
    3. When the deployment is built, Vercel triggers the deployment.ready webhook. This notifies integrators to begin checks on the deployment
    4. Vercel waits until all the created checks receive an update
    5. Once all checks receive a conclusion, aliases will apply, and the deployment will go live

    Learn more about this process in the Anatomy of Checks API

    You can build your Checks integration and publish it to the integration marketplace. Your integration should follow these guidelines:

    • Provide low or no configuration solutions for developers to run checks
    • A guided onboarding process for developers from the installation to the end result
    • Provide relevant information about the outcome of the test on the Vercel dashboard
    • Document how to go beyond the default behavior to build custom tests for advanced users
    Last updated on September 28, 2023