# Set up a routine

Have Mapstack repeat a job without you: write the brief once, choose when it runs, and each run updates your datasets and maps in place.

Video: Set up a routine (1 min 18 s): /images/docs/videos/set-up-a-routine.mp4

A routine is a job Mapstack does again and again without you. You write a brief in plain words once and choose when it runs; each run does the work and updates the datasets and maps in place, so anyone with the link sees the new data.

Use one to re-run last month's analysis with this month's figures, to refresh a map from a file a colleague keeps in Google Drive, or to flag every asset that has fallen due for inspection. Routines are set up in Settings, not by asking.

## Before you start

You need a Creator or Creator Max seat on a workspace that pays for its seats. On Free the form opens but does not save. A Viewer does not see **Routines**.

Have ready:

- **The brief.** Nobody is there to answer a question when a routine runs. Name the datasets and maps by title, say where the new data comes from and what to do if it looks wrong. See [What a routine can and can't do](/docs/automate/what-a-routine-can-do).
- **Any storage it reads.** Connect Google Drive, OneDrive or Dropbox first. See [Use files from Google Drive, OneDrive or Dropbox](/docs/cloud-storage/google-drive-onedrive-dropbox).

## Steps

1. **Select Routines, then New routine**

   **Routines** is in the sidebar. It opens the **Routines** section of Settings.

2. **Name it and write the instructions**

   Write the **Instructions** the way you would brief a colleague you cannot reach. The form's own example: "Refresh the store map from the latest orders and flag any region that dropped by more than 10%."

   > **Tip:** Let Mapstack draft them. In the session where you did the work, say what the routine should do and which datasets and maps it updates, then paste the instructions it writes into the form.

3. **Choose when it runs**

   Under **When should it run?**, choose **Once**, **Hourly**, **Daily**, **Weekdays** or **Weekly**, and the time. To have it run after a dataset is edited, or when another system calls it, use **Add another way to run**. See [Choose when a routine runs](/docs/automate/when-a-routine-runs).

4. **Choose the storage it may read**

   Under **Connectors**, add each connected service the routine may read from. It reads them without checking with you.

5. **Select Create routine**

   Then select **Run now** on the routine's page to try the brief before you rely on the schedule.

## What changes afterwards

The routine runs at the times you chose. Each run is a session: open it from **Runs** on the routine's page to read what Mapstack did, with any assumption it made.

On the routine's page you can pause it and switch it back to **Active**, **Edit** it, start it with **Run now**, or **Delete** it. Deleting a routine also deletes its past runs, and keeps the maps and datasets it made.

Every run uses part of the allowance of the Creator who made the routine, whoever or whatever started it. See [Your allowance](/docs/workspace/your-month).

## Common questions

**Can I ask Mapstack to set up a routine?**

No, routines are set up in Settings. Asked, Mapstack gives you the steps. It can write the instructions for you to paste into the form: say what the job is and which datasets and maps it should update.

**Can a routine run once a month?**

There is no monthly schedule. Run it weekly, start it with **Run now** each month, have another system start it, or have it run when the dataset it depends on is edited.

**Does a routine update my app?**

No. A routine updates datasets and maps. An app is changed only when someone asks for it in a session, so open a session and ask for the app to be updated.

**What happens to my routines if the workspace moves to Free?**

They stop running until the workspace has a Creator seat again. Each run that would have started is recorded as failed, with the reason.

## Related

- [Choose when a routine runs](https://mapstack.io/docs/automate/when-a-routine-runs.md)
- [What a routine can and can't do](https://mapstack.io/docs/automate/what-a-routine-can-do.md)
- [Use files from Google Drive, OneDrive or Dropbox](https://mapstack.io/docs/cloud-storage/google-drive-onedrive-dropbox.md)
- [Your allowance: how usage works](https://mapstack.io/docs/workspace/your-month.md)
- [Find what share of residents can walk to a bus stop, area by area](https://mapstack.io/docs/guides/walking-access-by-area.md)
- [Publish a map at a link that keeps itself up to date](https://mapstack.io/docs/guides/keep-a-published-map-current.md)
- [Build one screen that shows what is happening where](https://mapstack.io/docs/guides/operations-dashboard.md)
- [Re-run last month's analysis on this month's figures](https://mapstack.io/docs/guides/re-run-last-months-work.md)
