Holidays (cs)
Public holidays and significant days in the Czech Republic.
Functions
All functions are available in the main module. You can import them like this:
import * as holidays from 'holidays-cs';
Luxon is used for date manipulation.
You can pass a Date
object or a DateTime
object to the functions.
Responses are always DateTime
objects. If you need a Date
object,
you can use the response.toJSDate()
method.
Czech public holidays
import {DateTime} from 'luxon';
import {isPublicHoliday, getPublicHoliday} from 'holidays-cs';
isPublicHoliday(DateTime.fromISO('2024-01-01'));
isPublicHoliday(DateTime.fromISO('2024-01-02'));
isPublicHoliday(DateTime.fromISO('2024-11-17'));
getPublicHoliday(DateTime.fromISO('2024-11-17'));
You can get all public holidays for a given year:
import {getPublicHolidaysList} from 'holidays-cs';
getPublicHolidaysList(2024);
Shops status
In the Czech Republic, shops are closed on some public holidays.
import {DateTime} from 'luxon';
import {areShopsOpen, getShopsStatus} from 'holidays-cs';
areShopsOpen(DateTime.fromISO('2024-12-24'));
getShopsStatus(DateTime.fromISO('2024-12-25'));
areShopsOpen(DateTime.fromISO('2025-01-01'));
getShopsStatus(DateTime.fromISO('2025-01-01'));
Czech significant days
Significant days are not public holidays, but they are important in the Czech Republic.
import {DateTime} from 'luxon';
import {isSignificantDay, getSignificantDay} from 'holidays-cs';
isSignificantDay(DateTime.fromISO('2024-01-16'));
getSignificantDay(DateTime.fromISO('2024-01-16')).name;
Visit the significant days page for more information.
Easter
Easter Monday (Velikonoční pondělí) and Good Friday (Velký pátek)
are public holidays in the Czech Republic.
Easter date
Library can calculate the Easter date for a given year (it's Sunday):
import {getEaster} from 'holidays-cs';
getEaster(2024).toISODate();
getEaster(2025).toISODate();
Need more? Check out the Easter Date library.
Easter days
import {getGoodFriday, getHolySaturday, getEasterSunday, getEaster, getEasterMonday} from 'holidays-cs';
getGoodFriday(2024).toISODate();
getHolySaturday(2024).toISODate();
getEasterSunday(2024).toISODate();
getEaster(2024).toISODate();
getEasterMonday(2024).toISODate();
You can also check if a given date is Good Friday, Holy Saturday, Easter Sunday or Easter Monday:
import {isGoodFriday, isHolySaturday, isEasterSunday, isEasterMonday} from 'holidays-cs';
import {DateTime} from 'luxon';
isGoodFriday(DateTime.fromISO('2024-03-29'));
isHolySaturday(DateTime.fromISO('2024-03-30'));
isEasterSunday(DateTime.fromISO('2024-03-31'));
isEasterMonday(DateTime.fromISO('2024-04-01'));
Holy Week
You can also check if given date is part of the Holy Week.
Holy Week is the week before Easter plus Easter Monday.
Starts with Palm Sunday and ends with Easter Monday.
import {isHolyWeek, getHollyWeekInterval} from 'holidays-cs';
isHolyWeek(DateTime.fromISO('2024-03-29'));
getHollyWeekInterval(2024)
You can also get the name of the day in the Holy Week:
import {DateTime} from 'luxon';
import {getEasterDayName} from 'holidays-cs';
getEasterDayName(DateTime.fromISO('2024-03-29'));
Credits
License
MIT