This Page: cpearson.com/excel/easter.aspx

Last Updated: 06-Nov-2013

Copyright 1997 - 2014, Charles H. Pearson

Site Last Updated: 17-May-2015

Advanced Software

Design And Development

Design And Development

Office Integration Projects
NET Programming
XML Development

Easter Calculation

This page describes how to calculate the date of the Easter holiday.

Introduction

The calculation of the date of the Easter holiday for a given year is rather involved because of the way Easter is defined. Easter is always a Sunday, and that Sunday is the first Sunday after the first ecclesiastical full moon that occurs on or after March 21. There are various algorithms for the calculation of Easter, but most return an incorrect result for years greater than a value, which varies depending on the algorithm being used. Of the various algorithm, the most reliable is that used by the United States Naval Observatory.

Worksheet Formula For Easter

You can calculate the date of Easter with formula below. It is accurate for the years from 1900 to
2368. The formula is:

=FLOOR("5/"&DAY(MINUTE(YYYY/38)/2+56)&"/"&YYYY,7)-34

where YYYY is a four digit year between 1900 and 2368. The formula returns an incorrect for
some years past 2369.

VBA Function For Easter

The date of Easter can be computed in VBA. The algorithm below is from the United States Naval Observatory, at Computing The Date Of Easter.

Public Function EasterUSNO(YYYY As Long) As Long Dim C As Long Dim N As Long Dim K As Long Dim I As Long Dim J As Long Dim L As Long Dim M As Long Dim D As Long C = YYYY \ 100 N = YYYY - 19 * (YYYY \ 19) K = (C - 17) \ 25 I = C - C \ 4 - (C - K) \ 3 + 19 * N + 15 I = I - 30 * (I \ 30) I = I - (I \ 28) * (1 - (I \ 28) * (29 \ (I + 1)) * ((21 - N) \ 11)) J = YYYY + YYYY \ 4 + I + 2 - C + C \ 4 J = J - 7 * (J \ 7) L = I - J M = 3 + (L + 40) \ 44 D = L + 28 - 31 * (M \ 4) EasterUSNO = DateSerial(YYYY, M, D) End Function

You can call this from a worksheet cell with a formula like

=EasterUSNO(YYYY)

where YYYY is a four digit year.

A shorter function, shown below, returns the correct result for the years between 1900 and 2099.

Public Function EasterDate2(Yr As Integer) As Date Dim D As Integer D = (((255 - 11 * (Yr Mod 19)) - 21) Mod 30) + 21 EasterDate2 = DateSerial(Yr, 3, 1) + D + (D > 48) + 6 - ((Yr + Yr \ 4 + _ D + (D > 48) + 1) Mod 7) End Function

Calculate Easter For A Year

Enter a four digit year in the text box below to calculate the date of Easter for that year.

This page last updated: 30-Sept-2009. |