Epoch time, also known as Unix time or POSIX time, is just:
The number of seconds since 1970-01-01 00:00:00 UTC
(ignoring leap seconds)
🧠 Why use it?
- Simple, universal way to represent time
- Great for timestamps, logs, caching, or versioning
- Timezone-neutral
🔢 Example:
Human Time (UTC) | Unix Time |
---|---|
1970-01-01 00:00:00 | 0 |
2000-01-01 00:00:00 | 946684800 |
2025-06-16 18:00:00 | 1755405600 |
⚙️ Get current Unix time:
date +%s
(Linux/macOS)
import time
print(int(time.time()))
Hey everyone! We’re launching a limited-time token giveaway for all verified Dev.to authors. Head over here to see if you qualify (wallet connection required). – Dev.to Airdrop Desk