Unix Timestamp Converter
Introduction
A Unix timestamp (or epoch time) is the standard way computers represent time: a single integer counting the seconds since January 1, 1970 at midnight UTC, excluding leap seconds. It appears in database records, API responses, JWT tokens, log files, cron schedules, and cache expiration headers. While machines read these integers instantly, humans need them translated into calendar dates and clock times — often in multiple formats simultaneously.
The Unix Timestamp Converter serves developers, system administrators, and security analysts who need to decode timestamps from logs, verify token expiration, schedule cron jobs across timezones, or quickly look up a historical or future epoch value. The tool is split into two independent blocks:
- Block A (Unix timestamp → Date & Time): enter a numeric timestamp and see it rendered in 21 date and time formats, organized by standard family.
- Block B (Date & Time → Unix timestamp): pick a calendar date, time, and timezone offset, and get the equivalent timestamp in seconds, milliseconds, and microseconds.
Both blocks have their own timezone selector, so you can work in UTC for one direction and a custom offset for the other without cross-contamination.
Use Cases
Unix timestamp conversion is a recurring need across development, operations, and security work. Understanding these scenarios helps you integrate the tool into your workflow.
Debugging Logs and Error Reports
Application logs, database logs, and error tracking services often record timestamps as Unix epoch integers. When investigating an incident, paste the timestamp into Block A to see the human-readable time in multiple formats — RFC 1123Z for HTTP header correlation, ISO 8601 for JSON payloads, and relative time for recency assessment.
API Integration and Token Verification
JWTs, OAuth tokens, and API rate-limit headers frequently use Unix timestamps for expiration (exp), issuance (iat), and reset windows. Use the converter to verify that a token is still valid, check when it was issued relative to your current timezone, and confirm that your local clock matches the server's epoch time.
Cron Job and Scheduled Task Planning
When configuring cron jobs, scheduled database backups, or CI/CD pipeline triggers, you often need to express a wall-clock time as a Unix timestamp. Block B lets you pick a date, time, and timezone, then outputs the exact epoch value — no mental math or timezone juggling required.
Multi-Timezone Collaboration
Teams spread across timezones share log snippets, deployment windows, and incident timelines. Pasting a Unix timestamp into Block A and switching between UTC, Local, and Custom timezones reveals how the same instant reads in each team member's local time — eliminating ambiguity from timezone-converted strings.
How It Works
Unix time counts seconds from the epoch (January 1, 1970, 00:00:00 UTC). Each tick adds exactly one second. Because it is anchored to UTC, a Unix timestamp represents the same instant everywhere on Earth — timezone only matters when you render it as a human-readable string.
The tool uses the browser's native JavaScript Date object for all conversions. Every Date internally stores time as a single number: milliseconds since the Unix epoch. When you enter a timestamp, the tool constructs a Date and reads its UTC or local properties depending on the active timezone selector. When you enter a calendar date and time, the tool computes the difference from the epoch adjusted for the specified timezone offset.
Timestamp Units Across Ecosystems
Different platforms and languages use different epoch units. The tool's unit selector lets you match your source's precision:
| Unit | Used by | Example |
|---|---|---|
| Seconds | Go, PHP, Python, PostgreSQL, Ruby, cron | 10 digits |
| Milliseconds | JavaScript (Date.now()), Ethereum, .NET DateTimeOffset, Java System.currentTimeMillis() |
13 digits |
| Microseconds | Linux /proc/uptime, Go time.UnixMicro(), high‑resolution profiling |
16 digits |
The tool converts your input to seconds internally. If you paste a 13-digit value from JavaScript's Date.now(), set the unit to milliseconds and the tool handles the division.
Time Zone & DST
A Unix timestamp always represents the same physical instant. The timezone selector in each block only changes how that instant is displayed or interpreted.
- Relative: how long ago the request occurred – this row updates live against your current clock, so its value changes each time you open the page
- Local mode: uses your browser's system timezone, including automatic Daylight Saving Time adjustments.
- Custom mode: a numeric UTC offset between -12:00 and +14:00. The tool applies this offset directly without any DST correction — it treats your offset as a fixed wall clock.
When DST is in effect, the local timezone offset changes. The same timestamp displayed in Local mode may show a different hour than it did the previous month. This is expected: the timestamp is the same, but the local clock convention changed.
For the locale-formatted rows (Locale, Locale Date, Locale Time), the tool respects both the selected timezone and your browser's language settings. If you choose UTC mode, toLocaleString receives { timeZone: 'UTC' }, ensuring the locale format uses the correct timezone.
Usage
Block A — Timestamp to Date & Time
- Enter a Unix timestamp into the input field (digits only, optional minus sign for pre‑1970).
- Select the input precision: Seconds, Milliseconds, or Microseconds.
- Choose a timezone: UTC, Local (your system timezone), or Custom (enter an offset between -12 and +14 in half‑hour steps).
- Read the results — 21 date and time format rows update in real time.
Block B — Date & Time to Timestamp
- Enter the year directly. Use the dropdown menus for month, day, hour, minute, and second.
- Choose a timezone from the UTC/GMT selector: Local matches your system timezone; numeric entries like
UTC+8treat the input as wall clock time in that zone. - The timestamp results appear immediately in seconds, milliseconds, microseconds, hexadecimal, and relative time.
The two blocks operate independently. Changing Block A does not affect Block B and vice versa. This lets you compare timestamps side by side or lock a reference value while exploring different formats.
Tutorial
Scenario 1: Decode a timestamp from a server log
Your application log shows timestamp 1742345678 — an API call that failed. You need to know exactly when it happened and also check the HTTP-date format for correlating with HTTP response headers.
- Open the Unix Timestamp Converter.
- Type
1742345678into Block A's input field. - The results display 21 format rows, including:
- @ Format:
3/19/2025 @ 12:54:38 AM UTC(quick‑scan human format) - RFC 1123Z:
Wed, 19 Mar 2025 00:54:38 +0000(HTTP-date standard, matchesDateandLast-Modifiedheaders)
- @ Format:
- Relative: how long ago the request occurred – this row updates live against your current clock, so its value changes each time you open the page
- Switch the timezone to Local to see what time it was in your own timezone.
Scenario 2: Schedule a cron job at a specific time
You need a cron job to run at 3:30 AM Eastern Time on June 15, 2026. Eastern Daylight Time is UTC-4 in June.
- In Block B, set the date to June 15, 2026 and time to 03:30:00.
- Set the UTC/GMT selector to
UTC+4(EDT is UTC-4, so enter -4). - Read the Seconds value — this is your cron timestamp. The Hex and Relative rows also update, giving you a machine-readable and human-readable reference simultaneously.
Pro Tips
Format Use Cases
Each output format serves a specific purpose. Here is when to use each one:
| Format | When to use |
|---|---|
| @ Format | Quick visual scan — the compact M/D/YYYY @ HH:MM:SS AM/PM layout is readable at a glance |
| DateTime | SQL database inserts (YYYY-MM-DD HH:MM:SS), the most common string form outside JSON |
| ISO 8601 | JSON payloads (new Date().toISOString()), REST API request/response bodies |
| RFC 3339 | RSS feeds, Atom feeds, calendar subscriptions (iCalendar); used where ISO 8601 needs a stricter profile |
| RFC 1123Z | HTTP headers (Date, Last-Modified, Expires), cookies (expires attribute) |
| RFC 822 | Email headers (Date field), legacy newsgroup formats |
| RFC 850 | Older HTTP/1.0 implementations (rare today, kept for backwards compatibility) |
| ANSIC | Go's time.ANSIC constant — used when reading Go time.Time default output |
| RubyDate | Ruby's Time#ctime format; matches the classic Unix ctime output |
| DateOnly / TimeOnly | Go 1.20+ convenience constants — extract just the date or just the time |
| Kitchen | Go's 12‑hour clock format — quick wall‑clock reading |
| Locale | User interface display; respects the browser's language and cultural conventions |
| Hex | Low‑level debugging, firmware timestamps, embedded systems |
| Relative | Dashboard displays, "time since last event" UI elements |
Language Implementations
Get the current Unix timestamp in your language of choice:
// Go
time.Now().Unix() // seconds
time.Now().UnixMilli() // milliseconds (Go 1.17+)
// JavaScript
Math.floor(Date.now() / 1000) // seconds
Date.now() // milliseconds
// PHP
time(); // seconds
intval(microtime(true) * 1000); // milliseconds
# Python
import time; int(time.time()) # seconds
import time; int(time.time() * 1000) # milliseconds
General Tips
- Pre‑1970 timestamps: Enter negative values. December 1, 1960 at 00:00:00 UTC is
-286329600. - Hex input: Hexadecimal values (with or without
0xprefix) are parsed automatically — enter0x67DA15CEand see the decimal equivalent. - Compare timezones: Set Block A's timezone to UTC and Block A's timezone to Local simultaneously to see how the same instant renders in both.
Common Mistakes
Unix timestamps are simple in concept but easy to misuse. Here are the most common pitfalls.
Seconds vs Milliseconds Confusion
This is the single most frequent mistake. A 10-digit number like 1712345678 is seconds; a 13-digit number like 1712345678000 is milliseconds. Pasting milliseconds into a seconds-mode converter produces a date decades in the future (e.g., 54382 years from now). Always check the digit count before converting.
Ignoring Timezone in the Reverse Direction
When converting a date and time to a Unix timestamp (Block B), the selected timezone matters. Entering 2026-06-15 03:30:00 with UTC selected gives a different timestamp than the same wall-clock time with UTC+8 selected — the difference is exactly 8 hours. The resulting integer is correct for each interpretation, but if you forget to set the timezone, the output will not match what the receiving system expects.
Assuming Local Time Matches Server Time
When decoding a timestamp from a server log, the timestamp is already in UTC — timezone only affects how it is displayed. Switching Block A to Local mode changes the rendered clock time but does not change the underlying instant. If the output looks wrong, check the timezone selector first, not the timestamp value.
Using the Wrong Unit for Hex or Relative Values
Hex and relative time outputs are derived from the same internal conversion. Entering a timestamp in milliseconds with the unit set to seconds produces a hex value that represents a different instant. Always confirm that the unit selector matches the precision of your source data.
Alternatives
| Tool | Timestamp to Date | Date to Timestamp | 21+ Formats | Independent timezone per block | Client‑side |
|---|---|---|---|---|---|
| Toollect Unix Timestamp Converter | Yes | Yes | Yes (21) | Yes | Yes |
| unixtimestamp.com | Yes | Yes | ~5 | No | Yes |
| epochconverter.com | Yes | Yes | ~8 | No | Yes |
| site24x7.com | Yes | Yes | ~6 | Full IANA | Yes |
date -d @timestamp (Linux) |
Yes | No | ~3 | System TZ only | N/A |
Data Privacy
The Unix Timestamp Converter processes every conversion entirely within your browser. No timestamp, date, or timezone value you enter is transmitted to any server, stored in any database, or logged in any system.
All conversions are performed using the browser's native JavaScript Date object in memory. The tool page includes no analytics scripts, no tracking pixels, and no third-party embeds. No cookies, localStorage, or sessionStorage entries are created or read.
After the initial page load, the converter functions fully offline — you can disconnect from the internet and continue converting timestamps without interruption. You can verify this by using the tool in airplane mode or inspecting network activity in your browser's developer tools.
Troubleshooting
| Problem | Likely cause | Solution |
|---|---|---|
| Output shows a date in 1970 or 1969 | Input is being read in the wrong unit | Change the unit selector to match your input (seconds / ms / μs) |
| Date and time show the wrong moment | Timezone selector is set incorrectly | Switch to UTC to verify the base instant, then adjust to the correct offset |
| Locale row shows wrong time | Locale formatting ignores the Block A timezone selection | This was fixed — locale now respects the selected timezone. Verify you are on the latest version |
| Output does not update | The input contains non‑numeric characters | Clear the field and enter only digits and an optional leading minus |
| Relative time shows "just now" for a known past timestamp | Relative is calculated against the current system clock | This is expected — relative time always compares the timestamp to "now" |
| 13-digit input shows a date far in the future | The input is in milliseconds but the unit defaults to seconds | Switch the unit to "Milliseconds" |
Technical Specs
- Conversion engine: JavaScript
Dateobject (ECMAScript standard) - Timestamp range: Full JavaScript number range (±9 quadrillion seconds, covering billions of years)
- Supported input: Decimal integers, negative values (pre‑1970)
- Input precision: Seconds, milliseconds, or microseconds (configurable)
- Timezone support: UTC, local (browser system), custom GMT offset (-12 to +14 in 0.5‑hour steps); independent for each block
The 21 Format Families
| # | Group | Format | Example |
|---|---|---|---|
| 1 | Common | @ Format | 3/19/2025 @ 12:54:38 AM UTC |
| 2 | Common | DateTime | 2025-03-19 00:54:38 |
| 3 | Common | ISO 8601 | 2025-03-19T00:54:38+00:00 |
| 4 | Common | RFC 3339 | 2025-03-19T00:54:38Z (UTC uses Z) |
| 5 | RFC | RFC 1123Z | Wed, 19 Mar 2025 00:54:38 +0000 |
| 6 | RFC | RFC 822 | 19 Mar 25 00:54 UTC |
| 7 | RFC | RFC 822Z | 19 Mar 25 00:54 +0000 |
| 8 | RFC | RFC 1123 | Wed, 19 Mar 2025 00:54:38 UTC |
| 9 | RFC | RFC 850 | Wednesday, 19-Mar-25 00:54:38 UTC |
| 10 | Go | ANSIC | Wed Mar 19 00:54:38 2025 |
| 11 | Go | UnixDate | Wed Mar 19 00:54:38 UTC 2025 |
| 12 | Go | RubyDate | Wed Mar 19 00:54:38 +0000 2025 |
| 13 | Go | DateOnly | 2025-03-19 |
| 14 | Go | TimeOnly | 00:54:38 |
| 15 | Go | Kitchen | 12:54AM |
| 16 | Go | Stamp | Mar 19 00:54:38 |
| 17 | Locale | Locale | 3/19/2025, 12:54:38 AM (browser‑dependent) |
| 18 | Locale | Locale Date | 3/19/2025 |
| 19 | Locale | Locale Time | 12:54:38 AM |
| 20 | Other | Hex | 0x67DA15CE |
| 21 | Other | Relative | updates live |
Format Family Tree
The date and time formats in this tool derive from four lineages:
- RFC 822 (1982) defined the original email date format with a 2‑digit year. RFC 1123 (1989) superseded it with a 4‑digit year. RFC 1123Z is the same format using a numeric timezone offset (
+0000) instead of an alphabetic abbreviation (UTC). Together these cover HTTP headers (1123Z) and email formats (822). - ISO 8601 (1988) established the international standard for date and time representation. RFC 3339 (2002) profiles ISO 8601 for Internet use, adding requirements like the mandatory
Zfor UTC. Most modern APIs choose one of these two. - Go time constants (
ANSIC,UnixDate,RubyDate, etc.) are convenience layouts built into the Go standard library. They mirror POSIX conventions (ctimeoutput), RFC standards, and Go‑specific convenience forms (DateOnly,Kitchen,Stamp). - Locale formats use the browser's
Intl.DateTimeFormatAPI, which follows the Unicode Common Locale Data Repository (CLDR). The exact output depends on the user's browser language setting.
Compatibility
- Browsers: Chrome 90+, Firefox 90+, Safari 15+, Edge 90+
- Dependencies: None — plain JavaScript, zero third‑party libraries
- Data processing: 100% client‑side — zero network requests
Features
- Bidirectional conversion between Unix timestamps and human-readable dates
- 21 date and time format outputs including RFC 1123, ISO 8601, and Go standard formats
- Independent timezone selectors for both conversion directions
- Configurable input unit: seconds, milliseconds, or microseconds
- Client-side processing — no data sent to any server