Day of Year Calculator

Calculate what day of the year any date falls on with year progress.

Select Date

Saturday, July 18, 2026

Day 199
of 365 days in 2026

Year Progress

54.52%
199
Days Passed
166
Days Remaining

Date Details

Week of YearWeek 29
QuarterQ3 (73 days left)
MonthJuly (13 days left)
Leap YearNo

What Is the Day of the Year?

The day of the year (also called the ordinal date or Julian day within a year) is the sequential number of a specific date counting from January 1 as day 1. January 1 is day 1, December 31 is day 365 in ordinary years and day 366 in leap years. This compact representation replaces the month-day pair with a single integer, simplifying date arithmetic and enabling efficient year-over-year comparisons.

The day of the year is the standard date format used in meteorology for climate normals, in agriculture for growing season tracking, in military operations for concise date references, and in astronomy for various calculations. When meteorologists report that the historical average first frost date is "day 285," they mean October 12 (or 13 in a leap year) — a date you can look up regardless of the year.

This calculator shows the day of year for any selected date, the total days in that year, the days remaining until December 31, and the percentage of the year that has elapsed — giving you a complete picture of where any date falls within its annual cycle.

Day of Year Formula

The day of year is computed by accumulating the days in all months before the target month and adding the day of the target month.

Ordinal Date Formula

Day of Year = (days in months 1 to month-1) + day; February offset in leap years: +1 for March onwards

Where:

  • Standard year= Jan:31, Feb:59, Mar:90, Apr:120, May:151, Jun:181, Jul:212, Aug:243, Sep:273, Oct:304, Nov:334, Dec:365
  • Leap year= Same as standard year but all offsets from March onward are +1; Feb 29 = day 60
  • Year end= Day 365 (standard) or day 366 (leap) = December 31
  • Percent elapsed= (Day of Year / Total Year Days) × 100

Meteorological and Agricultural Uses

Climate scientists express seasonal patterns using day-of-year numbers to make year-over-year comparisons clean and leap-year-independent from March onward. A phenological event like "cherry blossoms peak at day 100" translates to April 10 in most years. Long-term climate records spanning decades use day-of-year as the x-axis in climate normal calculations, where averaging across many years is simpler with ordinal dates.

Agricultural extension services publish planting calendars in day-of-year format: corn should be planted between days 120-140 (April 30 to May 20) in many US regions. This is more compact and easier to apply year-to-year than calendar-date instructions that shift with Easter and other variable holidays in regional planting advice.

Day of Year in Computing

Most programming languages provide built-in functions to compute the day of year from a date object. In Python, datetime objects have a timetuple().tm_yday attribute. In JavaScript, (date - new Date(year, 0, 0)) / 86400000 gives the day of year. In SQL, DATE_PART('doy', date) returns the ordinal day in PostgreSQL. The compactness of a single integer makes it efficient for sorting, filtering, and indexing in date-sensitive databases.

In compressed or fixed-width date formats (like YYDDD used in some batch processing and COBOL systems), the day of year replaces the month-day pair with a three-digit number (001-366), saving one character compared to MMDD while remaining unambiguous. This YYDDD format is still encountered in mainframe-era data processing systems.

How Leap Years Affect Day of Year

The key difference between leap and standard years is that February 29 inserts as day 60, shifting all subsequent day numbers by 1. March 1 is day 60 in standard years but day 61 in leap years. Any time-series analysis that uses day-of-year numbers across multiple years must account for this shift to prevent spring events from appearing one day earlier in leap years compared to non-leap years.

One common workaround in climate science is to define a "365-day year" baseline by either ignoring February 29 leap days in all years, or interpolating between day 59 and day 61 in leap years to maintain a consistent 365-day axis. Different scientific communities use different conventions; this calculator always reports the actual day number in the actual year.

Worked Examples

Day of Year for June 15

Problem:

What is the day of year for June 15 in 2025 (non-leap)?

Solution Steps:

  1. 1Jan: 31, Feb: 28, Mar: 31, Apr: 30, May: 31 = 151 total days through May
  2. 2Add June 15: 151 + 15 = 166
  3. 3Days remaining: 365 - 166 = 199
  4. 4Percent elapsed: 166/365 × 100 = 45.5%

Result:

June 15, 2025 is day 166 of 365 (45.5% of the year elapsed; 199 days remaining).

Day of Year for February 29 (Leap Year)

Problem:

What is the day of year for February 29, 2024?

Solution Steps:

  1. 1January: 31 days (day 31)
  2. 2February: add 29 days (February 29 = day 31 + 29 = day 60)
  3. 3Total days in 2024: 366
  4. 4Percent elapsed: 60/366 × 100 = 16.4%

Result:

February 29, 2024 is day 60 of 366 in this leap year (16.4% elapsed).

Finding Date from Day Number

Problem:

Day 250 of a non-leap year — what calendar date?

Solution Steps:

  1. 1Cumulative: Jan 31, Feb 59, Mar 90, Apr 120, May 151, Jun 181, Jul 212, Aug 243, Sep 273
  2. 2Day 250 > 243 (Aug end) and ≤ 273 (Sep end): it falls in September
  3. 3Day within September: 250 - 243 = 7
  4. 4Day 250 = September 7

Result:

Day 250 of a non-leap year is September 7.

Tips & Best Practices

  • Day 100 = April 10 (standard) / April 9 (leap) — a useful mental anchor for the first quarter of the year.
  • Day 182 = July 1 (standard) — the approximate midpoint of the year, useful for half-year reviews.
  • For data analysis across years, always record both the year and the day number — the day number alone is ambiguous without the year.
  • Agricultural reports often specify planting windows as day ranges (e.g., days 120-140) — convert to your local calendar dates with this tool.
  • In leap years, any date from March 1 onward has a day number one higher than in non-leap years — account for this in time-series comparisons.
  • The 365-to-366 day-count shift in leap years means that 'day 300' falls on October 27 in standard years and October 26 in leap years.

Frequently Asked Questions

The day of year (ordinal date) resets to 1 every January 1 and runs from 1 to 365 or 366 within each year. The astronomical Julian Day Number (JDN) is a continuous count of days since January 1, 4713 BC — never resetting, currently in the 2.46 million range. They are completely different systems despite the shared use of 'Julian' in their names. This calculator computes the day-of-year (1-366), not the astronomical JDN.
The leap day is inserted at the end of February — it becomes day 60 (February 29), pushing March 1 from day 60 to day 61. Since all months after February depend on February's length in their cumulative count, every date in March through December has a day number one higher in leap years than in standard years. January and February day numbers are the same in both year types (January days are 1-31, February goes 32-59 in standard years or 32-60 in leap years).
Yes, with the leap year caveat: events in March through December will have day numbers that are 1 higher in leap years. If comparing 'first bloom day' across years, an event on day 100 in a leap year is the same calendar date as day 99 in a non-leap year (both are April 9 or 10, depending on exact dates). For rigorous cross-year comparison, either account for this one-day shift in leap years or use a standardized 365-day normalization.
YYDDD is a compact date format where YY is the 2-digit year and DDD is the 3-digit day of year (e.g., 25100 = day 100 of 2025 = April 10, 2025). This 5-digit format is used in legacy mainframe systems, COBOL batch processing, and some aviation and military systems for compact date storage. It eliminates month representation entirely, relying on the ordinal day instead. Modern systems prefer ISO 8601 (YYYY-MM-DD) for its human readability.
Day 1 is January 1 — ordinal dating starts at 1 (not 0), following the convention that the first day of the year is day 1. Some programming environments use 0-based indexing internally but present the user-facing day number as 1-based. January 1 is day 1, and December 31 of a standard year is day 365. The ISO 8601 standard for ordinal dates (e.g., 2025-166 meaning June 15, 2025) uses 1-based day numbering.

Sources & References

Last updated: 2026-06-06

💡

Help us improve!

How would you rate the Day of Year Calculator?

<>

Editorial Note

MyCalcBuddy Editorial Team

This page is maintained as an educational calculator reference.

Source

Formula Source: Standard Mathematical References

by Various

UpdatedLast reviewed: May 2026
CheckedFormula checks are based on standard references and internal QA review.

Privacy choices

MyCalcBuddy uses necessary storage for the site to work. Optional analytics, notifications, and future advertising features stay off unless you allow them.