-
Database
Standardize date, time, and timezone handling
Audits how the app stores and displays dates so users in different timezones stop seeing wrong times and off-by-one dates.
Free Prompt
Audit and fix date and time handling across my app. Find every place dates are stored, compared, parsed, and displayed: database columns, API payloads, form inputs, emails, and UI rendering.
Standardize: store all timestamps in UTC using a real timestamp type (never local time, never strings); convert to the user's timezone only at display time; use one date library consistently instead of mixing native Date parsing with library parsing; validate date inputs explicitly instead of relying on Date parsing, which accepts surprising strings differently across runtimes; and check every date comparison for timezone mistakes, like comparing a UTC timestamp against a local midnight. Audit boundary cases: subscriptions renewing at midnight, daily limits, anything that buckets by day, since those break for users ahead of or behind server time.
Don't change business logic about what dates mean; fix representation and conversion only. If a column already holds ambiguous local times, write a migration plan for it and flag the ambiguity instead of guessing the intended timezone.
Deliver: the storage and display standards applied, the list of timezone-sensitive comparisons fixed, the migration plan for any legacy columns, and verification: set a test user to a timezone 12+ hours from UTC and confirm dates render correctly around midnight.
What This Does / How This Helps
Makes dates mean one thing everywhere: stored in UTC, converted for display, compared correctly. Date bugs are the most common quiet data corruption in small apps. A user in Tokyo sees tomorrow's date, a subscription renews a day early, a daily limit resets at the wrong hour. Each bug looks minor; together they erode trust and corrupt billing-adjacent data. The verification step catches what code review misses: set a test account 12 hours off UTC and walk the app at its local midnight.
Want to skip doing this by hand?
Fortivibe audits your app for all of the areas these prompts cover (and more).