Date difference calculator
Runs entirely in your browser. Your files and data never leave your device.
| Difference | ||
|---|---|---|
| Total months | ||
| Total weeks | ||
| Total days | ||
| Weekdays | ||
| Weekend days | ||
| Total hours | ||
| Total minutes | ||
| Total seconds | ||
| Total milliseconds | ||
| Heartbeats (at 80 bpm) | ||
| Breaths (at 16 per minute) | ||
| Hours asleep (at 8 per night) | ||
| Full moons | ||
| Earth's travel around the Sun (km) |
About this tool
This tool works out the difference between two dates and times. It gives you a calendar breakdown in years, months, and days, plus the same span in weeks, days, hours, minutes, and seconds.
How does the calendar breakdown handle uneven month lengths?
Months don’t all have the same number of days, and a naive diff (just dividing the total days by 30) drifts from what a calendar actually shows. This tool instead finds the largest whole number of calendar months that fit between the two dates, then counts the leftover days on top. That means January 31 to March 1 comes out as 1 month and 1 day, not some fractional guess. It also accounts for leap years automatically, since it works from real calendar math rather than a fixed average year length. If the start date falls on the 31st and the target month is shorter, like February, the day gets clamped to that month’s last day before the remainder is counted.
What are the week/day/hour totals based on?
Below the calendar breakdown, the tool also shows the same span as flat totals: total weeks, total days, total hours, total minutes, and total seconds. Each of these is computed independently from the raw millisecond difference between the two dates, then rounded to the nearest whole unit. So “total hours” isn’t a remainder left over after days are subtracted; it’s the entire span measured directly in hours. That keeps exact-boundary spans from coming up one short due to rounding.
Is my data sent anywhere?
No. Both dates and the whole calculation stay in your browser; nothing is sent to a server. That matters if you’re timing a contract deadline, a medical date, or anything else you’d rather keep private.
Common uses: working out someone’s exact age, counting the days until a deadline or event, checking how long a stay or project ran, or converting a span into a different unit. See the Wikipedia article on ISO 8601 for background on date and time formats.