Version 2025-07 is the last API version to support React-based UI components. Later versions use web components, native UI elements with built-in accessibility, better performance, and consistent styling with Shopify's design system. Check out the migration guide to upgrade your extension.
DatePicker
The date picker component lets customers select dates using a visual calendar interface. Use it when customers benefit from seeing dates in context of the full month, such as selecting dates relative to today or needing weekday context.
The component supports single dates, multiple dates, and date ranges. For text date entry, use DateField.
Supported targets
- Customer
Account::Kitchen Sink - customer-account.
footer. render-after - customer-account.
order-index. announcement. render - customer-account.
order-index. block. render - customer-account.
order-status. announcement. render - customer-account.
order-status. block. render - customer-account.
order-status. cart-line-item. render-after - customer-account.
order-status. cart-line-list. render-after - customer-account.
order-status. customer-information. render-after - customer-account.
order-status. fulfillment-details. render-after - customer-account.
order-status. payment-details. render-after - customer-account.
order-status. return-details. render-after - customer-account.
order-status. unfulfilled-items. render-after - customer-account.
order. action. menu-item. render - customer-account.
order. action. render - customer-account.
order. page. render - customer-account.
page. render - customer-account.
profile. addresses. render-after - customer-account.
profile. announcement. render - customer-account.
profile. block. render - customer-account.
profile. company-details. render-after - customer-account.
profile. company-location-addresses. render-after - customer-account.
profile. company-location-payment. render-after - customer-account.
profile. company-location-staff. render-after - customer-account.
profile. payment. render-after
Supported targets
- Customer
Account::Kitchen Sink - customer-account.
footer. render-after - customer-account.
order-index. announcement. render - customer-account.
order-index. block. render - customer-account.
order-status. announcement. render - customer-account.
order-status. block. render - customer-account.
order-status. cart-line-item. render-after - customer-account.
order-status. cart-line-list. render-after - customer-account.
order-status. customer-information. render-after - customer-account.
order-status. fulfillment-details. render-after - customer-account.
order-status. payment-details. render-after - customer-account.
order-status. return-details. render-after - customer-account.
order-status. unfulfilled-items. render-after - customer-account.
order. action. menu-item. render - customer-account.
order. action. render - customer-account.
order. page. render - customer-account.
page. render - customer-account.
profile. addresses. render-after - customer-account.
profile. announcement. render - customer-account.
profile. block. render - customer-account.
profile. company-details. render-after - customer-account.
profile. company-location-addresses. render-after - customer-account.
profile. company-location-payment. render-after - customer-account.
profile. company-location-staff. render-after - customer-account.
profile. payment. render-after
Anchor to PropertiesProperties
Configure the following properties on the DatePicker component.
- Anchor to selectedselectedselectedTTrequiredrequired
A date, an array of dates, or a range object with
startand/orendkeys indicating the selected dates. When a range is set, dates between the boundaries will be selected.- Anchor to defaultYearMonthdefaultYearMonthdefaultYearMonthYearMonthYearMonth
Default uncontrolled year and month to display. Ignored when year/month navigation is controlled.
- Anchor to disableddisableddisabledDisabledDate[] | booleanDisabledDate[] | boolean
Disabled dates, days, and/or ranges, or the date picker. Unbound range disables all dates either from
startdate or toenddate.truedisables the date picker.- Anchor to onChangeonChangeonChange(selected: T) => void(selected: T) => void
A callback fired when the selected date or dates change. This callback is called with a string, an array of strings or a range object representing the selected dates. This component is controlled, so you must store these values in state and reflect it back in the
selectedprops.- Anchor to onYearMonthChangeonYearMonthChangeonYearMonthChange(yearMonth: { year: number; month: number; }) => void(yearMonth: { year: number; month: number; }) => void
A callback fired when the displayed year and month change. This callback is called with an object indicating the year/month the UI should change to. When year/month navigation is controlled you must store these values in state and reflect it back in the
prop.- Anchor to readOnlyreadOnlyreadOnlybooleanboolean
Whether the date picker is read-only and can't be edited. Read-only date pickers remain focusable and their state is announced by screen readers where applicable.
- Anchor to yearMonthyearMonthyearMonthYearMonthYearMonth
Controlled year and month to display. Use in combination with
. Makes year/month navigation controlled.
YearMonth
{year: number; month: number} | YearMonthStringYearMonthString
A year/month string using the simplified ISO 8601 format (`YYYY-MM`)
stringDisabledDate
DateString | DateRange | DayStringDateString
stringDateRange
- end
Last day (inclusive) of the selected range
DateString - start
First day (inclusive) of the selected range
DateString
DayString
keyof typeof DayDay
- Sunday
0 - Monday
1 - Tuesday
2 - Wednesday
3 - Thursday
4 - Friday
5 - Saturday
6
Anchor to ExamplesExamples
Anchor to Select a date from a calendarSelect a date from a calendar
Use date picker to display a visual calendar that customers can browse and select dates from. This example shows a basic calendar view with selectable dates.Select a date from a calendar

Select a date from a calendar
React
import {
reactExtension,
DatePicker,
} from '@shopify/ui-extensions-react/customer-account';
export default reactExtension(
'customer-account.page.render',
() => <Extension />,
);
function Extension() {
return <DatePicker selected="2021-06-01" />;
}JS
import {extension, DatePicker} from '@shopify/ui-extensions/customer-account';
export default extension('customer-account.page.render', (root) => {
const datepicker = root.createComponent(DatePicker, {
selected: '2021-06-01',
});
root.appendChild(datepicker);
});Anchor to Best practicesBest practices
- Set a default view: Use
defaultViewto open the calendar to the most relevant month, such as the current or next month. - Restrict invalid dates: Use
disallowwith date ranges anddisallowDayswith day names to prevent customers from selecting unavailable dates. - Choose the right selection mode: Use
type="range"for booking windows and the default single mode for one-off date selections.
Anchor to LimitationsLimitations
- Time selection isn't available.