Every example is a complete Vue file. Copy it into an app that has the registry installed, or open it in StackBlitz. Click the first day, then the last; or Tab into the grid and press Enter on each.
Two months side by side
A report period. number-of-months="2" shows two months, so a range across a month end is easy to pick. max-value stops it at today.
November - December 2026
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
Sales report: Nov 18 – Dec 1, 2026
RangeCalendarReport.vue
<script setup lang="ts">
import type { DateRange } from 'reka-ui'
import type { Ref } from 'vue'
import { DateFormatter, getLocalTimeZone, today } from '@internationalized/date'
import { ref } from 'vue'
import { RangeCalendar } from '@/components/ui/range-calendar'
// The period of a sales report, two months side by side. Starts as the last 14 days.
const end = today(getLocalTimeZone())
const value = ref({ start: end.subtract({ days: 13 }), end }) as Ref<DateRange>
const format = new DateFormatter('en-US', { dateStyle: 'medium' })
const show = (range: DateRange) => range.start && range.end
? format.formatRange(range.start.toDate(getLocalTimeZone()), range.end.toDate(getLocalTimeZone()))
: 'Pick the last day'
</script>
<template>
<div class="grid justify-items-start gap-(--bh-space-100)">
<RangeCalendar
v-model="value"
:number-of-months="2"
:max-value="end"
class="rounded-(--bh-radius-card) border-(length:--bh-border-width-default) border-(--bh-color-border)"
/>
<p class="text-(--bh-color-text-subtle) [font:var(--bh-font-body-default)]">Sales report: {{ show(value) }}</p>
</div>
</template>Range picker in a popover
A date filter above a table. The button shows the range, or “Any date” until one is picked.
Order date
RangeCalendarPicker.vue
<script setup lang="ts">
import type { DateRange } from 'reka-ui'
import type { Ref } from 'vue'
import { DateFormatter, getLocalTimeZone, today } from '@internationalized/date'
import { CalendarDays } from '@lucide/vue'
import { ref } from 'vue'
import { Button } from '@/components/ui/button'
import { Popover, PopoverContent, PopoverTrigger } from '@/components/ui/popover'
import { RangeCalendar } from '@/components/ui/range-calendar'
// A date range filter above an order table: the button shows the range, the popover holds the calendar.
const value = ref({ start: undefined, end: undefined }) as Ref<DateRange>
const format = new DateFormatter('en-US', { dateStyle: 'medium' })
const label = () => value.value.start && value.value.end
? format.formatRange(value.value.start.toDate(getLocalTimeZone()), value.value.end.toDate(getLocalTimeZone()))
: 'Any date'
</script>
<template>
<div class="grid justify-items-start gap-(--bh-space-050)">
<span id="order-dates-label" class="text-(--bh-color-text) [font:var(--bh-font-label-default)]">Order date</span>
<Popover>
<PopoverTrigger as-child>
<Button variant="outline" aria-labelledby="order-dates-label order-dates-value">
<CalendarDays />
<span id="order-dates-value">{{ label() }}</span>
</Button>
</PopoverTrigger>
<PopoverContent class="w-auto p-0" align="start">
<RangeCalendar v-model="value" :max-value="today(getLocalTimeZone())" initial-focus />
</PopoverContent>
</Popover>
</div>
</template>Limits
Promotion dates: from tomorrow, at most 60 days ahead. Days outside the limits are disabled.
December 2026
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
RangeCalendarLimited.vue
<script setup lang="ts">
import type { DateRange } from 'reka-ui'
import type { Ref } from 'vue'
import { getLocalTimeZone, today } from '@internationalized/date'
import { ref } from 'vue'
import { RangeCalendar } from '@/components/ui/range-calendar'
// Promotion dates: from tomorrow, within the next 60 days. Days outside that can't be picked.
const first = today(getLocalTimeZone()).add({ days: 1 })
const value = ref({ start: first.add({ days: 3 }), end: first.add({ days: 9 }) }) as Ref<DateRange>
</script>
<template>
<RangeCalendar
v-model="value"
:min-value="first"
:max-value="first.add({ days: 60 })"
class="rounded-(--bh-radius-card) border-(length:--bh-border-width-default) border-(--bh-color-border)"
/>
</template>