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

# How rest and consecutive-duty limits work

> Max consecutive work days, minimum rest days per week, minimum rest hours between shifts, and post-shift recovery time — all hard constraints the engine never violates.

PlanMyRounds enforces four separate rest-related rules. They overlap in purpose but apply differently, and all of them are **hard constraints**: the engine will not produce a schedule that violates any of them.

## The four rules

| Rule | What it limits |
| - | - |
| **Max consecutive work days** | The longest unbroken run of working days a doctor can have. Set per roster in the [creation wizard](https://www.planmyrounds.com/docs/rosters/creating-a-roster.md). |
| **Min rest days per week** | The minimum number of days off every doctor must get in each Monday to Sunday window. Also set per roster. |
| **Min rest hours between shifts** | The minimum gap between the end of one shift and the start of the next, for any doctor. Always enforced, regardless of other settings. |
| **Recovery time** | How much rest a doctor needs after working a specific shift, before being assigned again. Set per [Shift Requirement](https://www.planmyrounds.com/docs/shifts/overview.md) — not per roster. A longer recovery window applies after two consecutive shifts in a row, when [Allow back-to-back duties](https://www.planmyrounds.com/docs/rosters/roster-constraints.md#work-and-rest-rules) is turned on. |

> [!NOTE]
>
> Recovery time is configured on the shift itself, so it travels with that shift into every roster and Shift Schedule that uses it — you don't set it again per roster.

## Why a doctor might still look overworked

If a doctor is working what looks like too many nights or too tight a rotation despite these rules, check:

* Whether **Allow back-to-back duties** is on for that roster — it permits some consecutive-day patterns (like night into day) that would otherwise be blocked.
* Whether the shift's recovery time is actually set to a meaningful value, not left at a default that's too short for your policy.
* Whether the perceived overload is actually workload **imbalance** rather than a rule violation — see [Fairness](https://www.planmyrounds.com/docs/concepts/fairness.md) for how the engine balances total hours, which is a separate, softer mechanism from these hard rest limits.

## Next steps

> **[Roster constraints](https://www.planmyrounds.com/docs/rosters/roster-constraints.md)**
>
> The full rule set, including these alongside leave and staffing.

> **[Create a shift](https://www.planmyrounds.com/docs/shifts/creating-shifts.md)**
>
> Set a shift's recovery time settings.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.