Why the Solar Calendar has 13 months of 28 days
Every Solar Calendar year starts on a Monday, which is why its leap years add a whole week instead of a day.
A calendar whose months all start on a Monday needs months made of whole weeks. The Solar Calendar has 13 months of 28 days, and its year starts on the first Monday on or after the March equinox. In October 2026 I rebuilt it from scratch around one small, tested core.
13 times 28
28 days is exactly four weeks, and 13 months of 28 days is 364 days, which is exactly 52 weeks. That makes every month identical. The 1st is always a Monday and the 28th always a Sunday, in every month of every year. A date tells you its weekday without looking it up.
The idea isn’t new. Moses Cotsworth proposed a 13-month, 28-day calendar in the early 1900s, the International Fixed Calendar. One of the sets of month names in the app borrows his extra month, Sol.
The app is built around that sameness. In the month view the big numbers 1 to 28 never move, and only the small Gregorian dates and the month name change. The year view is a single table, one row for each day of the month and one column for each month, which only works because every month is the same shape.
Starting at the equinox
A calendar of 364 days falls behind the sun by about a day and a quarter each year, so something has to bring it back. I wanted the year tied to the seasons, and it starts at the spring equinox in March. I also wanted weeks never to break, which puts the start on a Monday: the first Monday on or after the equinox.
The equinox happens at one instant, which falls on different dates in different time zones. The calendar takes the equinox’s date in UTC, so it’s the same everywhere.
A leap week
Cotsworth kept an extra day outside the weeks, his Year Day. A calendar whose every year starts on a Monday can’t: the gap between one year’s start and the next is always a whole number of weeks, 364 days or 371, never 365 or 366.
A normal year is 13 months of 28 days. When the next first Monday after the equinox is 371 days away, the year ends with a seven-day leap week. That happens in 35 of the 200 years from 1900 to 2099, about one year in six. Solar 2026 is a normal year, from Monday 23 March 2026 to Sunday 21 March 2027. Solar 2028 ends with a leap week, 19 to 25 March 2029.
Iceland’s old calendar used the same fix: a 364-day year, with a leap week called sumarauki, “summer addition”, added every few years. The Old Norse set of month names in the app uses that name for the leap week.
Calculating the equinox
The equinox comes from the formulas in chapter 27 of Meeus’s Astronomical Algorithms. They’re accurate to about a minute and take microseconds. The tests cross-check them against the astronomy-engine library. With the equinox in hand, the start of the year is a few lines:
export function yearStart(year: number): DayNumber {
const equinox = equinoxDay(year);
return equinox + ((7 - weekday(equinox)) % 7);
}
export function yearLength(year: number): number {
return yearStart(year + 1) - yearStart(year);
}
A year has a leap week exactly when yearLength is 371.
No arithmetic on Date objects
Adding days to JavaScript Date objects is a classic trap: they carry a time and a time zone, and a calendar built that way repeats or skips the days the clocks change.
The core never adds days to a Date. Every date is an integer: the number of days since 1 January 1970. Converting to and from year, month and day uses Howard Hinnant’s published algorithms, and the weekday is simple arithmetic:
/** 0 = Monday to 6 = Sunday. Day 0 (1970-01-01) was a Thursday. */
export function weekday(n: DayNumber): number {
return (((n + 3) % 7) + 7) % 7;
}
A Date is only used to read the current time and to format times for display. A day number carries no time or zone for a clock change to shift.
The same rules everywhere
One small TypeScript core with no DOM in it holds every rule, and everything uses it: the month and year views, printing, the converter, and the Cloudflare Worker that builds the subscribable calendar feed and the “today” badge.
You can try it at solar.dealmobile.co.uk.
More on Solar Calendar
Featured projects
-
Apple News API
Publish articles and live coverage to Apple News from PHP, with the whole Apple News Format built from objects.
-
GitHub Auditor
Health, access and activity reports for more GitHub and Bitbucket repositories than you can keep in your head.
-
PrintMD
Markdown in, and a designed PDF, Word or PowerPoint file out. Its PDF service runs on your own computer.
-
Where Should I Live
Which city would leave you best off? Cities ranked by take-home pay, living costs, visas and the way you live.
-
TurboPush
Resumable uploads of very large files from the browser, put back together by one PHP class on the server.
More writing
-
Many sessions at once, and what still needs me
Fifteen coding-agent sessions across two Linux boxes, one session that watches the rest, what it may answer for me, what it never may, and why a yes it passes on gets checked against what I typed.
-
61 public repos of agent tooling, none installed, six ideas kept
One author, 61 public repositories of coding-agent tooling: what I checked before any of it got near my Linux boxes, why none of it was installed, and the six ideas I built my own way.
-
Rules a coding agent cannot talk its way round
The hook that reads every command a coding agent wants to run on my Linux boxes: what it refuses, the 27 proofs that its tests fail when a rule is taken out, and the four lines every report opens with.
-
Dozens of repos, one person
46 repositories and two Linux boxes with nobody else on them: the diary, the decision table, the rebuild guide and the job that keeps both sets of clones in step.