Nager.Holiday is the official .NET client for Nager.Date, a popular project for querying public holidays worldwide. It allows you to easily retrieve holiday data for 100+ countries via the API.
⚠️ Commercial use requires sponsorship. Support the project here.
The full list of supported countries can be found here.
The NuGet package is available via NuGet
PM> install-package Nager.Holiday
using var holidayClient = new HolidayClient();
var holidays = await holidayClient.GetHolidaysAsync(2022, "br");
foreach (var holiday in holidays)
{
//holiday...
//holiday.Date -> The date
//holiday.LocalName -> The local name
//holiday.Name -> The english name
//holiday.Global -> Is this public holiday in every county (federal state)
//holiday.Counties -> Is the public holiday only valid for a special county ISO-3166-2 - Federal states
//holiday.Type -> Public, Bank, School, Authorities, Optional, Observance
}
- Retrieve holidays for 100+ countries
- Supports subdivisions (states or regions) where available
- Easy-to-use .NET API client
- Commercial usage requires sponsorship