Relay

Getting Started

Install the Relay CLI, link your repository, and run your first pipeline.

Prerequisites

Before you begin, make sure you have the following:

  • Node.js 18.0 or later
  • npm, yarn, or pnpm
  • Git
  • A Relay account (sign up or sign in)

Install the CLI

Install globally via npm
The recommended way to install Relay
npm i -g @relay/cli

Verify the installation:

relay --version

Initialize a project

Run relay init in your repository root. Relay generates a starter relay.yaml and links the repo to your organization.

cd my-app
relay init

You'll be prompted to:

  1. Authenticate with relay login (opens a browser session)
  2. Select an organization and repository
  3. Choose a pipeline template (Node, Docker, or monorepo)

Run your first pipeline

Trigger a local dry run or push to start a cloud build:

relay run --local
relay run --branch main

Connect your repository

Relay watches Git events automatically once the repo is linked. Add a status badge to your README:

[![Relay](https://api.relay.dev/badges/org/repo)](https://relay.dev/org/repo)

Note: Self-hosted runners require a separate registration step. See Runners.

Next steps

Ready to ship

On this page