NewLife.Holiday
Chinese holiday and adjusted-workday identification library with built-in annual holiday data and lunar festival support. Works fully offline and supports .NET Framework 4.5, .NET Standard 2.0/2.1 and modern .NET. 中国节假日与调休识别库,内置年度假期数据并支持农历节日判定,完全离线运行。
Install
| Product | Versions |
|---|---|
| .NET Standard | |
| Other |
README
NewLife.Holiday - Chinese Holiday Library
Chinese holiday and adjusted-workday identification library with a built-in annual holiday database, lunar festival support and fully offline operation.
Installation
dotnet add package NewLife.Holiday
Quick start
using NewLife.Holiday;
var isHoliday = "2026-10-01".ToDateTime().IsChinaHoliday();
Guangxi March 3rd Festival:
using NewLife.Holiday;
var isHoliday = "2026-04-18".ToDateTime().IsGuangxiHoliday();
Localized holiday names
HolidayInfo.DisplayName returns the holiday name in the current UI language, while Name keeps the original Chinese source:
var info = HolidayExtensions.China.Query("2026-02-15".ToDateTime()).FirstOrDefault();
Console.WriteLine(info?.DisplayName); // Spring Festival
The word list ships 11 languages (English, Simplified Chinese, Traditional Chinese, Spanish, German, Japanese, French, Portuguese, Russian, Korean and Arabic); unsupported languages fall back to Chinese.
Documentation
License
MIT License © 2002-2026 NewLife Team
Changes from Previous Version
Adoption Assessment
Assess this package against its supported frameworks, license, maintenance signals and dependency graph before making it a project standard.
Related Guides & Workflows
Learn how to evaluate, integrate, or audit this package in your .NET project.