> ## Documentation Index
> Fetch the complete documentation index at: https://docs.buildbetter.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Health

> The customer health queue — risk scores, ARR distribution, renewal pressure, and payment state across every account

The Health page (`/success/health`) is the renewal-and-risk command center. Every account in your workspace gets a health score from 0–100, and Health surfaces the ones at the dangerous end first.

## What's at the Top

Four summary cards across the top of the page:

* **Critical accounts** — count at the most-urgent risk level
* **At-risk accounts** — count one tier down from critical
* **Renewing in 30 days** — accounts approaching renewal soon
* **Protected ARR** — total ARR across the visible portfolio

Below the cards, a **risk distribution bar chart** shows ARR split across critical / at-risk / healthy buckets — useful for an at-a-glance sense of how much revenue is exposed.

## The Live Health Table

The main content is the customer table. Each row shows:

| Column              | Meaning                                               |
| ------------------- | ----------------------------------------------------- |
| **Account**         | Company name, logo (via Clearbit), and domain         |
| **Health score**    | 0–100, color-coded by risk                            |
| **Risk level**      | Critical / At risk / Healthy badge                    |
| **Active users**    | Current vs. licensed (e.g., 12 / 25)                  |
| **ARR**             | Annual recurring revenue from linked contracts        |
| **Days to renewal** | Pulled from the active contract's end date            |
| **Risk factors**    | Up to 2 inline plus *"+N more"* — hover for full list |
| **Actions**         | Row menu (route to another section, untrack, open)    |

Click any row to open the [Customer Detail](./customer-detail) page — or for accounts without a clean domain match, the legacy detail sheet.

## Filtering and Searching

* **Risk filter** — All / Critical / At risk / Healthy
* **Search** — by company name, domain, or contact email
* **Untracked toggle** — hide or show accounts you've explicitly excluded from monitoring

## The Last-Updated Bar

Sits above the table:

* **Last updated** — timestamp of the last health refresh
* **Refresh** — manual sync button (kicks off a recompute)
* **Settings** — opens the **Health Settings** sheet (see below)

## Health Settings Sheet

Click the Settings button to configure:

### Scoring Weights

How much each input contributes to the score:

* **Adoption** — PostHog-driven active-user metrics
* **Payment state** — Stripe past-due / failed payments
* **Renewal pressure** — proximity to contract end date

### Integration Status

Per-source health and connection state for Salesbricks, Stripe, PostHog. If any are disconnected, the page surfaces an inline warning with a quick-link to fix it.

### Untracked Accounts

A free-form **Untracked reason** field for explaining why an account is excluded (e.g., *"Test workspace"*, *"Internal use"*). The reason shows in the untracked filter view.

## Risk Factors — Where the Scores Come From

Every account's health score breaks down into specific factors, each cited to a data source:

* *"−8 Low product adoption (PostHog)"*
* *"−5 Payment failed (Stripe)"*
* *"−3 Approaching renewal (Salesbricks)"*
* *"−10 Multiple support escalations (BuildBetter signals)"*

This is the *why* behind every score — and the basis for the conversation you'll have with the account.

## Routing Accounts Out of Health

Health is the triage surface — but most accounts don't *stay* here. Use the row menu to route an account:

* **Route to Convert** — if a trial is looking ready to upgrade
* **Route to Pipeline** — if an expansion opportunity is forming
* **Route to Contracts** — when you need to review the renewal in detail
* **Route to Re-engage** — if you've decided to retire the account but want to keep a winback window open

The destination page shows the account at the top with a *"Routed from Health"* badge.

## Demo Mode

If your integrations aren't connected, the **"Preview with demo data"** button loads the Pied Piper sample dataset so you can explore the layout, scoring, and filters before wiring up Salesbricks, Stripe, or PostHog. The page shows a subtle banner while demo mode is active.

## Empty and Error States

* **Not connected** — *"Health is not connected yet"* alert with **Open Integrations** and **Preview with demo data** buttons
* **Load error** — alert with **Retry** and **Preview with demo data** options
* **No results** — *"No accounts match the current filters"* with a hint about the active filter

<Tip>
  The Critical bucket should be small. If you have more than \~5–10 critical accounts at a time, the threshold is probably too generous. Open Health Settings and tighten the scoring weights so the queue stays actionable.
</Tip>
