User Rating 0.0
Total Usage 0 times
Category Time & Date
Beginning of date sequence
Leave empty to fill entire matrix
Tokens: YYYY, MM, DD, ddd, MMM, HH, mm, ss, W, Q
Presets:
Is this tool helpful?

Your feedback helps us improve.

About

A date matrix is a two-dimensional grid where each cell contains a date value computed from a starting point, interval, and fill pattern. This structure appears in project timelines, fiscal calendars, sprint planning boards, and scientific data collection schedules. Manual creation in spreadsheets introduces transcription errors - off-by-one mistakes in month boundaries, incorrect leap year handling, or timezone-induced date shifts. The cost compounds: a single misaligned date in a 52-week production schedule cascades into missed deadlines and contractual penalties.

This tool generates matrices using the proleptic Gregorian calendar with proper handling of variable-length months (accounting for the 28/29/30/31 day variance) and leap year rules (divisible by 4, except centuries unless divisible by 400). Output formats follow ISO 8601 standards when applicable. The matrix populates in row-major order by default, with options for column-major fill, random distribution, or custom stride patterns. Export to CSV preserves Excel/Sheets compatibility; JSON export maintains type fidelity for programmatic consumption.

date generator date matrix calendar grid date table scheduling tool date formatter time grid

Formulas

Each cell value Ci,j in the matrix is computed from the base date D0 plus an offset determined by the cell's linear index and the selected interval:

Ci,j = D0 + k × Δt

Where k is the linear index calculated based on fill direction:

k = i × cols + j (row-major)
k = j × rows + i (column-major)

The interval Δt supports multiple units: 1 day, 7 days (week), 1 month, 1 year. Month and year intervals use calendar arithmetic rather than fixed millisecond offsets to preserve day-of-month alignment where possible.

ISO week number W follows the ISO 8601 definition: week 1 contains the first Thursday of the year. Calculated as:

W = floor(ordinal + 10 weekday7)

Leap year determination follows the Gregorian rule:

isLeap = (y mod 4 = 0) (y mod 100 0 y mod 400 = 0)

Reference Data

Format TokenOutput ExampleDescription
YYYY20254-digit year
YY252-digit year
MM01 - 12Month (zero-padded)
M1 - 12Month (no padding)
MMMJan, Feb, MarMonth abbreviation
MMMMJanuary, FebruaryFull month name
DD01 - 31Day of month (zero-padded)
D1 - 31Day of month (no padding)
dddMon, Tue, WedWeekday abbreviation
ddddMonday, TuesdayFull weekday name
d0 - 6Day of week (0=Sunday)
HH00 - 23Hour (24h, zero-padded)
hh01 - 12Hour (12h, zero-padded)
mm00 - 59Minutes (zero-padded)
ss00 - 59Seconds (zero-padded)
AAM, PMMeridiem (uppercase)
aam, pmMeridiem (lowercase)
W1 - 53ISO week number
WW01 - 53ISO week (zero-padded)
Q1 - 4Quarter of year
DDD1 - 366Day of year
X1735689600Unix timestamp (seconds)
x1735689600000Unix timestamp (milliseconds)
[text]textEscaped literal text

Frequently Asked Questions

When adding months, the tool uses calendar arithmetic: adding 1 month to January 31 yields February 28 (or 29 in leap years), clamping to the last valid day. This prevents invalid dates like February 31. If you need consistent 30-day periods, use the "days" interval set to 30 instead.
The matrix dimensions (rows × columns) define the total cell count. If your date range with the selected interval would produce more dates than available cells, the matrix fills completely and stops. Excess dates are truncated. To capture all dates, increase matrix dimensions or use a larger interval.
Yes. Set your end date before your start date, and the tool automatically generates dates in descending order. Alternatively, use the "Reverse" fill option which populates the matrix from the last cell backward regardless of date order.
The tool implements ISO 8601 week numbering exactly: week 1 is the week containing the first Thursday of January. This means December 31 might belong to week 1 of the following year, and January 1-3 might belong to week 52 or 53 of the previous year. The calculation accounts for all edge cases including years starting on different weekdays.
The tool supports matrices up to 100 rows × 100 columns (10,000 cells). This limit prevents browser memory issues and maintains responsive performance. For larger datasets, consider generating multiple matrices or exporting to CSV for processing in specialized software.
Excel recognizes ISO 8601 format (YYYY-MM-DD) automatically in most regional settings. For guaranteed compatibility, use the ISO format or include column headers. The JSON export preserves dates as ISO strings, which JavaScript Date constructors parse correctly.