# Monitor a page

> Watch a page for changes, then alert you, run a workflow or wake an AI agent.

Source: https://usewrit.app/docs/monitors/

A monitor checks one page on a schedule and records every change it finds. You choose what to watch:
the text of an element, such as a price or a stock label, or a zone of the page compared as an image.
When something changes, Writ can notify you, run a workflow, wake an AI agent or call a webhook.

## Create a monitor

There are two ways in. Both make the same kind of monitor.

### With Scribe

Open **Scribe** and pick **Watch a website and react**, or type what you want,
for example *“tell me when the price of this book drops below 40”* with the page address. Scribe
finds what to watch, asks you how often to check (each choice shows its price in credits) and what to do
when it changes, then creates the monitor.

### With the wizard

-

1. **Open the wizard**

Go to **Create** and pick **Monitor a page manually**, then **Set it up manually**. You can also click **New** on the **Monitors** page.

-

2. **Enter the page**

Paste the page in **URL to monitor**. If the page is behind a login, click **Use a persona** and pick the [persona](https://usewrit.app/docs/personas) to sign in as.

-

3. **Pick what to watch**

The page opens in a live preview. Choose how a gesture on it is read:

- **Click**: click an element to watch its text.
- **Area**: drag over a part of the page to add the elements inside it.
- **Zone**: drag a rectangle to watch it as an image. Any visual change counts.
- **CSS**: type a CSS selector yourself.
- **Browse**: use the page normally, for example to close a banner or open a tab.

Or describe it in **Tell me what to watch.**, for example *“the price and the availability”*, and Writ's AI adds the matching selectors. You can watch several elements in one monitor.

-

4. **Set the schedule and test**

Under **How often to check**, pick an interval, or a daily or weekly time. Turn on **Always render in a browser** only for a page whose content appears after its scripts run. Pick a **Region** if the page differs by country Pro and up. Click **Test now** to run one check and see what it reads.

-

5. **Choose what happens on a change**

Click **Run an automation when it changes** to wire a reaction now, or add one later from the monitor's page. A monitor with no reaction still records every change.

> **tip:** Watch the smallest element that holds the value. A whole product card also changes when a review count or a banner changes; the price element changes only when the price does.

## Review changes

Open a monitor from **Monitors**. The **Overview** tab shows its health, the
last and next check, and recent changes. The **Changes** tab lists every change, filtered
by **All**, **Unreviewed** or **Reviewed**. Each change shows the
old and the new value; a zone shows the before and after images. Click **Mark reviewed** on
one change, or **Mark all reviewed**.

The monitor's page also has these controls:

- **Check now** runs one check outside the schedule.
- **Pause** stops the checks; **Resume** starts them again. A paused monitor costs nothing.
- **Automatic repair** (on by default): when a selector stops matching because the page changed its layout, Writ finds the value again on the new page, and asks Scribe to repair the monitor if it cannot.
- **Settings** changes the page, the selectors, the schedule and the browser option.

## React to a change

On the monitor's page, pick a reaction. Each one is saved as an automation that starts on the
monitor's change, so you can edit it later under [Automations](https://usewrit.app/docs/automations-webhooks).

| Reaction | What happens |
| --- | --- |
| Notify me | Sends a notification on the channels and to the recipients you pick: email, in-app, Slack, Discord, Telegram, SMS and others set up in Notifications. |
| Run a workflow | Runs one of your APIs or workflows, for example to buy, to save a record or to post a message. |
| Wake an AI agent | An AI agent opens the page with the change (the difference and the values read) and works the task you wrote. Wakes are spaced at least 10 minutes apart. |
| Call a webhook | Sends a POST request to your URL with the change. |
| Build in Automations | Opens the automation builder for conditions, loops and several steps. |

To act only past a threshold, such as a price at or below 40, ask your AI assistant to wire the
monitor with a threshold, or add a **Condition** step in the automation.

## How often it checks and what it costs

Each check costs **0.5 credit** when Writ reads the page without a browser, and **5 credits** when it needs a browser. A check stays on the cheaper read unless you turn on **Always render in a browser**, the monitor watches a zone, or Writ finds that the content
only appears in a browser. For example, a plain check every hour is 24 checks a day: 12 credits a day,
about 360 a month. The wizard shows the number of checks per day for the schedule you pick.

Your plan sets the fastest schedule:

| Plan | Fastest check without a browser | Fastest check in a browser |
| --- | --- | --- |
| Free | 5 min | 15 min |
| Starter | 1 min | 10 min |
| Pro | 1 min | 10 min |
| Growth | 30 s | 5 min |
| Scale | 10 s | 2 min |
| Enterprise | 10 s | 2 min |

A schedule faster than your plan allows is refused with a message that names your plan's minimum.
When owners or admins turn on **Respect robots.txt** in **Settings → Overview**,
a monitor cannot be created on a page the site's robots.txt disallows.

> **limit:** A monitor compares the visible text of the elements you picked, or the pixels of a zone. If a site blocks Writ's servers, the check fails and the monitor page says what gets past the block; see Blocks, CAPTCHAs and hand-offs.

## From your AI assistant or your code

### From your AI assistant

Ask in plain words, for example *“watch the price on this page every hour and message me on Slack when it drops below 40”*. Your assistant uses two tools, in this order:

- `writ_create_monitor` creates the monitor: the page, a CSS selector or a visual zone, and the interval. It returns the monitor id.
- `writ_wire_monitor` attaches the reaction: `notify`, `workflow` or `ai_task`, with an optional price `threshold`.

Writ's answer includes a short `tell_user` sentence that the assistant passes on to you.

### Over REST

Monitors are called targets in the API. Send the page, a selector and the interval in milliseconds.

POST `https://api.usewrit.app/api/targets` wt_ key

```bash
curl -X POST https://api.usewrit.app/api/targets \
  -H "Authorization: Bearer $WRIT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://books.toscrape.com/catalogue/a-light-in-the-attic_1000/index.html",
    "selector": ".product_main .price_color",
    "check_period_ms": 3600000
  }'
```

```python
import os, requests

res = requests.post(
    "https://api.usewrit.app/api/targets",
    headers={"Authorization": f"Bearer {os.environ['WRIT_API_KEY']}"},
    json={
        "url": "https://books.toscrape.com/catalogue/a-light-in-the-attic_1000/index.html",
        "selector": ".product_main .price_color",
        "check_period_ms": 3600000,  # every hour
    },
)
res.raise_for_status()
print(res.json()["id"])
```

```typescript
const res = await fetch("https://api.usewrit.app/api/targets", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.WRIT_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    url: "https://books.toscrape.com/catalogue/a-light-in-the-attic_1000/index.html",
    selector: ".product_main .price_color",
    check_period_ms: 3_600_000, // every hour
  }),
});
const monitor = await res.json();
console.log(monitor.id);
```

```json
{
  "id": 42,
  "url": "https://books.toscrape.com/catalogue/a-light-in-the-attic_1000/index.html",
  "checkType": "content",
  "selector": ".product_main .price_color",
  "checkPeriodMs": 3600000,
  "scheduleKind": "interval",
  "enabled": true,
  "requiresPlaywright": false,
  "preferredRegion": null,
  "createdAt": "2026-10-31T14:20:05+00:00",
  "lastCheckedAt": null,
  "changesCount": 0
}
```

Useful body fields

- `url` (string, required): The page to watch.
- `selector` (string): A CSS selector whose text is compared.
- `check_period_ms` (integer): Time between checks. Below your plan's minimum, the call answers 402 with the code interval_too_short.
- `requires_playwright` (boolean): Check in a browser every time (5 credits a check).
- `persona_id` (integer): A persona whose signed-in session the check uses.
- `preferred_region` (string): Where to check from, such as eu-west. Pro and up.

Read the changes a monitor found, newest first:

GET `https://api.usewrit.app/api/targets/{id}/changes` wt_ key

```bash
curl "https://api.usewrit.app/api/targets/42/changes?limit=20" \
  -H "Authorization: Bearer $WRIT_API_KEY"
```

```python
import os, requests

res = requests.get(
    "https://api.usewrit.app/api/targets/42/changes",
    headers={"Authorization": f"Bearer {os.environ['WRIT_API_KEY']}"},
    params={"limit": 20},
)
for change in res.json():
    print(change["lastDetectedAt"], change["oldContent"], "->", change["newContent"])
```

```typescript
const res = await fetch("https://api.usewrit.app/api/targets/42/changes?limit=20", {
  headers: { Authorization: `Bearer ${process.env.WRIT_API_KEY}` },
});
for (const change of await res.json()) {
  console.log(change.lastDetectedAt, change.oldContent, "->", change.newContent);
}
```

```json
[
  {
    "id": "5512",
    "targetId": "42",
    "timestamp": "2026-10-31T09:14:02+00:00",
    "firstDetectedAt": "2026-10-31T09:14:02+00:00",
    "lastDetectedAt": "2026-10-31T09:14:02+00:00",
    "oldContent": "£51.77",
    "newContent": "£45.17",
    "selectorName": "Price",
    "reviewed": false
  }
]
```

`POST /api/targets/{id}/run` runs a check now, and `PATCH /api/targets/{id}/toggle?enabled=false` pauses a monitor. The key needs the `checks` permission.

## On Writ Desktop

Monitors in Writ Cloud check from Writ's servers, so they keep running while your computer is off.
Each check is charged in credits, as shown above.

Monitors on Writ Desktop check from your computer, over your own connection, and cost nothing. The
fastest schedule is every minute. They run while Writ Desktop is open; the app can start with your
computer so they keep running.

Faster checks, checks from another region, and email or SMS alerts need a linked Writ Cloud account.

## Next

-
- [Automations and webhooks](https://usewrit.app/docs/automations-webhooks): Build multi-step reactions with conditions and loops.
-
- [Notifications](https://usewrit.app/docs/notifications): Set up email, SMS, Slack and the other channels.
-
- [Harvest a site](https://usewrit.app/docs/crawl): Collect a whole site or a section into a dataset.
-
- [Sign-ins and secrets](https://usewrit.app/docs/personas): Watch pages behind a login with a persona.
