Looking to hire Laravel developers? Try LaraJobs

laravel-hellenic-holidays maintained by p-potsikas

Description
Laravel package for Greek public holidays and observances.
Author
P. Potsikas
Last update
2026/06/20 17:30 (dev-main)
License
Links
Downloads
0

Comments
comments powered by Disqus

Laravel Hellenic Holidays

██╗  ██╗███████╗██╗     ██╗     ███████╗███╗   ██╗██╗ ██████╗
██║  ██║██╔════╝██║     ██║     ██╔════╝████╗  ██║██║██╔════╝
███████║█████╗  ██║     ██║     █████╗  ██╔██╗ ██║██║██║
██╔══██║██╔══╝  ██║     ██║     ██╔══╝  ██║╚██╗██║██║██║
██║  ██║███████╗███████╗███████╗███████╗██║ ╚████║██║╚██████╗
╚═╝  ╚═╝╚══════╝╚══════╝╚══════╝╚══════╝╚═╝  ╚═══╝╚═╝ ╚═════╝

██╗  ██╗ ██████╗ ██╗     ██╗██████╗  █████╗ ██╗   ██╗███████╗
██║  ██║██╔═══██╗██║     ██║██╔══██╗██╔══██╗╚██╗ ██╔╝██╔════╝
███████║██║   ██║██║     ██║██║  ██║███████║ ╚████╔╝ ███████╗
██╔══██║██║   ██║██║     ██║██║  ██║██╔══██║  ╚██╔╝  ╚════██║
██║  ██║╚██████╔╝███████╗██║██████╔╝██║  ██║   ██║   ███████║
╚═╝  ╚═╝ ╚═════╝ ╚══════╝╚═╝╚═════╝ ╚═╝  ╚═╝   ╚═╝   ╚══════╝

Wake up, Laravel... The Greek holidays have been calculated. Follow the Orthodox Easter offset.

Laravel package for Greek public holidays and observances, implemented in pure PHP.

The package supports Laravel 10, 11 and 12, and provides a service, facade and helper for common holiday and working-day checks.

Installation

Install from Packagist:

composer require p-potsikas/laravel-hellenic-holidays

If the package has not been published to Packagist yet, install directly from GitHub:

composer config repositories.laravel-hellenic-holidays vcs https://github.com/p-potsikas/laravel-hellenic-holidays
composer require p-potsikas/laravel-hellenic-holidays:dev-main

Publish the configuration file:

php artisan vendor:publish --tag=hellenic-holidays-config

Laravel auto-discovery registers the service provider automatically.

Usage

use HellenicHolidays;

$holidays = HellenicHolidays::getHolidays(2026);
$result = HellenicHolidays::isHoliday('2026-12-25');
$next = HellenicHolidays::getNextHoliday();
$isWorkingDay = HellenicHolidays::isWorkingDay('2026-06-19');

You can also import the facade class directly:

use Potsikas\LaravelHellenicHolidays\Facades\HellenicHolidays;

Helper:

$holidays = hellenic_holidays()->getHolidays(2026);

The facade exposes:

HellenicHolidays::getHolidays(2026);
HellenicHolidays::isHoliday('2026-12-25');
HellenicHolidays::getNextHoliday('2026-12-24');
HellenicHolidays::getHolidaysByType(2026, 'national');
HellenicHolidays::isWorkingDay('2026-06-19');
HellenicHolidays::orthodoxEaster(2026);

Controller Example

<?php

namespace App\Http\Controllers;

use Potsikas\LaravelHellenicHolidays\Facades\HellenicHolidays;

final class HolidayController
{
    public function index(int $year): array
    {
        return array_map(
            fn ($holiday) => $holiday->toArray(),
            HellenicHolidays::getHolidays($year)
        );
    }

    public function check(string $date): array
    {
        return HellenicHolidays::isHoliday($date)->toArray();
    }
}

Included Holidays

Fixed holidays:

  • 01-01 Πρωτοχρονιά / New Year's Day
  • 06-01 Θεοφάνεια / Epiphany
  • 25-03 Ευαγγελισμός της Θεοτόκου - Εθνική Εορτή / Greek Independence Day
  • 01-05 Εργατική Πρωτομαγιά / Labour Day
  • 15-08 Κοίμηση της Θεοτόκου / Dormition of the Mother of God
  • 28-10 Επέτειος του Όχι / Ohi Day
  • 25-12 Χριστούγεννα / Christmas Day
  • 26-12 Σύναξη της Θεοτόκου / Synaxis of the Mother of God

Movable holidays based on Orthodox Easter:

  • Καθαρά Δευτέρα, Easter -48
  • Μεγάλη Παρασκευή, Easter -2
  • Μεγάλο Σάββατο, Easter -1
  • Κυριακή του Πάσχα, Easter
  • Δευτέρα του Πάσχα, Easter +1
  • Αγίου Πνεύματος, Easter +50

Αγίου Πνεύματος is included as an optional holiday. Enable optional holidays with include_optional_holidays.

Configuration

return [
    'locale' => 'el',
    'include_saturdays_as_non_working_day' => true,
    'include_sundays_as_non_working_day' => true,
    'include_optional_holidays' => false,
    'custom_holidays' => [
        '2026-12-31' => [
            'name_el' => 'Ειδική Αργία',
            'name_en' => 'Special Holiday',
            'type' => 'custom',
            'is_public_holiday' => true,
        ],
    ],
    'overridden_holidays' => [],
    'moved_holidays' => [
        'labour_day' => [
            2026 => '2026-05-04',
        ],
    ],
];

For payroll, legal or HR use, verify exceptional transferred holidays and year-specific ministerial decisions before relying on generated results.

Data Objects

Holiday contains:

  • date: Carbon\CarbonImmutable
  • nameEl: Greek name
  • nameEn: English name
  • type: HolidayType
  • isPublicHoliday: public holiday flag
  • key: stable identifier

HolidayResult contains:

  • isHoliday: boolean
  • holiday: Holiday|null

Both objects include toArray() methods.

Attribution

This package is an original PHP/Laravel implementation. The idea and public API shape are inspired by the MIT-licensed eliac7/hellenic-holidays JavaScript package.

No JavaScript source code from that project is included.

License

The MIT License (MIT). See LICENSE.