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

# Layer restrictions

Make a layer active only during specific weekday + hour windows.

# Layer restrictions

Each layer has a **restriction** that controls when the layer is "active." When a layer is inactive, the schedule resolution falls through to the next layer.

## The four types

**None (24/7) — default**

The layer is always active. Use for catch-all secondary layers.

  **Weekday business hours**

Active Mon–Fri within `[start_hour, end_hour)` in the layer's timezone. The dashboard defaults this to 9 AM → 5 PM but you pick the window.

    Example: senior engineers cover business hours, secondary layer covers nights/weekends.

  **Weekends only**

Active all hours Saturday + Sunday in the layer's timezone.

    Example: dedicated weekend on-call team rotates separately from weekday rotation.

  **Custom (days + hours)**

Pick a subset of weekdays (any combination of Sun..Sat) and an optional hour window.

    Hour windows can wrap midnight: `start = 22, end = 6` covers nights (10 PM until 6 AM next morning).

    Examples:
    - Mon/Wed/Fri 6 AM → 12 PM (early shift, M/W/F)
    - Tue/Thu only (no hour window) — entire days
    - Daily 22:00 → 06:00 (overnight pager)

## How "active" is computed

For a given moment T:
1. Convert T to the layer's timezone.
2. If `restriction_type === 'none'` → active.
3. Else check that the weekday matches AND the hour falls in the configured window (if any).

DST transitions are handled by `Intl.DateTimeFormat` with the layer's timezone — handoffs and restrictions work correctly across spring-forward / fall-back.

## When a layer is inactive

The layer's "Currently on call" badge shows a gray "off-duty" pill. The user is still listed (for transparency), but they're skipped when the dispatcher picks who to page. Resolution proceeds to the next layer.

## Recipes

**[Business hours + nights](/guides/multi-layer-schedules)**

Two-layer pattern.
  **[Follow-the-sun](/guides/multi-layer-schedules)**

Three-layer pattern.

## Edge cases

**Restriction window wraps midnight**

Set `start_hour = 22, end_hour = 6`. The layer is active 10 PM that day until 6 AM the next day. Always evaluated in the layer's timezone.

  **No layer is active right now**

The schedule's `primary` is null. Slack pages will say "No one on call". Add a catch-all layer with `restriction_type = 'none'` if this isn't acceptable.

  **Holiday detection**

Not built-in (yet). Use a [fixed shift](/guides/overrides-and-shifts) to assign someone to specific holiday days, or use a per-day [override](/guides/overrides-and-shifts) for one-off coverage.