---
title: "Discussion on \"A Day Isn't 24 Hours: Fixing Date Math & DST Bugs\" | Hashnode"
description: "Discussion on \"A Day Isn't 24 Hours: Fixing Date Math & DST Bugs\". A calendar day isn't always 24 hours. Learn why duration math breaks during Daylight Saving Time and how to write resilient calendar arithmetic in your code."
url: "https://hashnode.com/posts/why-a-day-is-not-24-hours/6af43d852eb9c13dc84f3b03"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [A Day Isn't 24 Hours: Fixing Date Math & DST Bugs](https://doogal.dev/why-a-day-is-not-24-hours?utm_source=hashnode&utm_medium=feed)

A calendar day isn't always 24 hours. Learn why duration math breaks during Daylight Saving Time and how to write resilient calendar arithmetic in your code.

8h ago · 5 min read · doogal.dev  
Read the article

-   [#softwareengineering](https://hashnode.com/tag/softwareengineering)
-   [#javascript](https://hashnode.com/tag/javascript)
-   [#webdevelopment](https://hashnode.com/tag/webdevelopment)
-   [#programming](https://hashnode.com/tag/programming)

## Written by

[Doogal Simpson](https://hashnode.com/@doogal)

@doogal

  
[View profile](https://hashnode.com/@doogal)

"hey doogal, what is .... ?"

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
