Unix Timestamp
Human-Readable Formats
UTC:
-
ISO 8601:
-
Local Time:
-
Locale String:
-
Relative Time:
-
Date & Time
Unix Timestamps
Seconds:
-
Milliseconds:
-
Timestamp in Multiple Timezones
Calculate Time Difference
Batch Conversion
Understanding Timestamps
⏰ What is Unix Time?
Unix time (also called POSIX time or Epoch time) is the number of seconds that have elapsed since January 1, 1970 00:00:00 UTC, not counting leap seconds.
It's timezone-independent and widely used in programming, databases, and APIs because it's a simple integer that's easy to store and compare.
📋 Common Timestamp Formats
- Unix (seconds):
1736140800- Most common format - Unix (milliseconds):
1736140800000- JavaScript default - ISO 8601:
2026-01-06T04:00:00.000Z- International standard - RFC 2822:
Mon, 06 Jan 2026 04:00:00 GMT- Email headers - Relative: "2 hours ago" - Human-friendly display
🎯 When to Use Each Format
- Unix timestamps: Database storage, API responses, date calculations
- ISO 8601: API requests, JSON data, international applications
- Local time: UI display for end users in their timezone
- Relative time: Social media posts, activity feeds, notifications
- UTC: Server logs, coordination across multiple timezones
⚠️ Common Gotchas
- Unix timestamps are always in UTC by default
- JavaScript uses milliseconds, most other systems use seconds
- Daylight Saving Time can cause unexpected issues
- Always store timestamps in UTC, convert to local time only for display
- The Unix epoch is January 1, 1970 (not 1900!)
- The Year 2038 problem: 32-bit timestamps will overflow on January 19, 2038