Unix Timestamp Converter
Convert Unix timestamps to readable dates or convert dates back to Unix time. Work with seconds, milliseconds, UTC, ISO 8601 and timezones directly in your browser.
Convert Unix Timestamps & Dates
Convert Unix seconds or milliseconds into readable dates, or convert a date and timezone back into Unix time.
Current Unix Seconds
—
Current Unix Milliseconds
—
Enter Unix seconds such as
1767225600
or milliseconds such as
1767225600000.
The date has no timezone by itself. The timezone selected below determines which real-world instant this wall-clock time represents.
Your browser reports detecting... .
Timestamp Results
The same instant represented using Unix seconds, Unix milliseconds and common date-time formats.
Unix Seconds
—
Unix Milliseconds
—
Input Unit
—
Relative Time
—
Timezone
—
UTC Offset
—
Position relative to the Unix epoch
—
Date & Time Formats
View the converted instant in UTC, your browser timezone, the selected timezone and standardized formats.
UTC
—
Browser Local Time
—
Selected Timezone
—
ISO 8601
—
RFC 2822
—
Date Components
Individual components in the selected timezone.
Year
—
Month
—
—
Day
—
—
Hour
—
Minute
—
Second
—
Millisecond
—
Timezone Offset
—
Unix Seconds vs Milliseconds
One of the most common timestamp bugs is using the correct number with the wrong unit.
Unix Seconds
1767225600
Traditional Unix time counts seconds elapsed from the Unix epoch.
Unix Milliseconds
1767225600000
JavaScript commonly counts milliseconds, making the equivalent number 1000 times larger.
1767225600
× 1000 =
1767225600000
The Unix Epoch
Unix time measures elapsed time relative to one fixed UTC reference point.
Timestamp 0
1970-01-01T00:00:00Z
1 January 1970 at 00:00:00 UTC
-1
One second before the epoch
0
The Unix epoch
1
One second after the epoch
Timestamps in PHP & JavaScript
PHP
$timestamp = time();
// Unix seconds
echo $timestamp;
PHP's
time()
returns Unix time in seconds.
JavaScript
const timestamp = Date.now();
// Unix milliseconds
console.log(timestamp);
JavaScript's
Date.now()
returns milliseconds from the Unix epoch.
Unix Timestamps in Laravel
Laravel normally works with Carbon date-time objects, but Unix timestamps are easy to obtain when an API or external system requires them.
Unix seconds
now()->timestamp
Unix milliseconds
now()->valueOf()
A Unix Timestamp Does Not Contain a Timezone
A Unix timestamp identifies one specific instant. It does not say that the instant belongs to London, Accra, New York, Tokyo or any other timezone.
Timezones are applied when that instant is converted into a local wall-clock date and time.
Date-to-Timestamp Conversion Can Be Affected by Daylight Saving
Some timezones change their UTC offset during the year. When clocks move forward, certain local clock times may never occur. When clocks move back, some local clock times can occur twice.
SwiftVecto validates the selected local date against the timezone when converting it to an instant and rejects local times that do not exist.
Timestamp Auto Detection Is a Convenience
Modern Unix timestamps expressed in seconds are commonly around ten digits, while millisecond timestamps are commonly around thirteen digits. Auto Detect uses that practical difference to determine the likely unit.
For unusual historic or far-future values, select Seconds or Milliseconds explicitly rather than relying on automatic detection.
Private Browser-Based Timestamp Conversion
Timestamp conversion and timezone calculations are performed directly inside your browser.
- No file upload is required.
- Dates and timestamps do not need to be sent to SwiftVecto's server.
- Browser timezone information is obtained locally using JavaScript.
- ISO, RFC and relative-time values are generated locally.
Continue with These Tools
Finished using Unix Timestamp Converter? Here are some related tools that people commonly use next to complete their workflow faster.
Cron Expression Builder
Build, validate and explain standard Unix cron expressions. Create schedules visually, understand each field and preview upcoming run times directly in your browser.
JSON Formatter & Validator
Format, beautify, minify and validate JSON online instantly. Detect invalid JSON, organise nested data and create clean, readable JSON directly in your browser.
URL Encoder / Decoder
Encode or decode URLs and URL components instantly. Convert special characters to percent-encoded values, decode encoded text and work with URI components or form-style query data directly in your browser.
UUID Generator
Generate secure random UUID v4 identifiers instantly online. Create single or bulk UUIDs, choose uppercase or lowercase output, remove hyphens and copy or download results directly in your browser.
Number Base Converter
Convert integers between binary, octal, decimal, hexadecimal and custom number bases from 2 to 36. Supports very large integers, negative values and instant browser-based conversion.
Regex Tester
Test JavaScript regular expressions online with live match highlighting, capturing groups, named groups, flags and replacement previews directly in your browser.
How to Convert Unix Timestamps and Dates
Use the SwiftVecto Unix Timestamp Converter to convert Unix timestamps into readable dates or convert dates and times back into Unix timestamps. Work with seconds or milliseconds, inspect UTC and local representations, and copy ISO 8601 or epoch values instantly.
Overview
Unix time represents a point in time as the number of elapsed seconds since the Unix epoch at 00:00:00 UTC on 1 January 1970. Many systems, APIs, databases and backend applications use Unix timestamps because they provide a compact and timezone-independent way to represent an instant. Traditional Unix timestamps normally use seconds, while JavaScript timestamps commonly use milliseconds. This difference is important because the same digits interpreted using the wrong unit can produce a completely different date. The SwiftVecto Unix Timestamp Converter supports both directions: timestamp to date and date to timestamp. It also provides UTC, ISO 8601 and timezone-aware representations so developers can understand exactly what instant a timestamp represents.
Benefits
How It Works
Unix time starts at 00:00:00 UTC on 1 January 1970.
A Unix timestamp in seconds counts elapsed seconds from that epoch.
A JavaScript-style timestamp commonly counts elapsed milliseconds from the same epoch.
Timestamp-to-date conversion interprets the numeric value using the selected unit.
The resulting instant is then formatted in UTC, local time and other selected timezones.
Date-to-timestamp conversion interprets the entered calendar date and time using the selected timezone.
The resulting instant is converted into both Unix seconds and Unix milliseconds.
ISO 8601 output expresses the instant using a standardized date-time format.
Timezone changes affect how an instant is displayed but do not change the underlying moment in time.
When converting a wall-clock date to a timestamp, the selected timezone determines which actual instant that date represents.
Normal interactive calculations happen directly in the browser.
How to Use This Tool
-
1Choose Timestamp to Date or Date to Timestamp.
-
2For timestamp conversion, enter the Unix timestamp.
-
3Choose Seconds, Milliseconds or Auto Detect.
-
4Review the UTC, local and ISO representations.
-
5Select another timezone when you need to inspect the same instant elsewhere.
-
6For date conversion, enter the date and time.
-
7Choose the timezone in which that date should be interpreted.
-
8Convert the date to Unix seconds and milliseconds.
-
9Review the formatted output to verify the resulting instant.
-
10Copy the timestamp or formatted date required by your application.
-
11Use Current Time to populate the converter with the present instant.
Helpful Tips
- Traditional Unix timestamps are usually expressed in seconds.
- JavaScript Date timestamps are normally expressed in milliseconds.
- If a timestamp appears roughly 1000 times larger than expected, milliseconds may have been used instead of seconds.
- Unix timestamps represent an instant rather than a timezone.
- Timezone affects how an instant is displayed, not the underlying point in time.
- Use UTC when comparing timestamps across servers or services.
- ISO 8601 values ending in Z represent UTC.
- Do not remove or add timezone information to a date without understanding how that changes interpretation.
- When converting a date that has no timezone, choose the intended timezone explicitly.
- Daylight-saving rules can affect local date-to-timestamp conversion.
- The same wall-clock time can sometimes occur twice during a daylight-saving transition.
- Some local times may not exist when clocks move forward.
- Prefer explicit timestamps or ISO 8601 values with offsets for data exchanged between systems.
- Use current timestamps for debugging only when reproducibility is not required.
- Database fields and APIs may use seconds, milliseconds or formatted date strings, so always check the expected contract.
Common Uses
Convert an API timestamp into a readable date.
Convert a JavaScript Date.now() value into UTC.
Convert a Laravel-generated timestamp into milliseconds for frontend code.
Convert an ISO date into Unix seconds.
Compare a timestamp against the current time.
Find the local date represented by a UTC timestamp.
Check whether an API token expiration timestamp has passed.
Convert database epoch values into human-readable dates.
Convert a scheduled event date into epoch seconds.
Inspect the same timestamp in London, New York and Tokyo.
Determine whether a numeric timestamp is probably seconds or milliseconds.
Generate a current Unix timestamp for testing.
Worked Examples
The following examples demonstrate how this tool can be used in realistic scenarios.
Unix Seconds to Date
A timestamp such as 1767225600 represents a specific instant measured in seconds from the Unix epoch. The converter can display that instant in UTC, ISO 8601 and other selected timezones.
Milliseconds vs Seconds
A JavaScript timestamp such as 1767225600000 contains milliseconds. Dividing by 1000 gives the equivalent Unix-seconds value 1767225600. Interpreting the millisecond value as seconds would produce an invalid or extremely distant date.
Date to Unix Timestamp
Entering a calendar date and time together with a timezone identifies one specific instant. That instant can then be represented as both Unix seconds and Unix milliseconds.
Same Instant, Different Timezones
A timestamp represents one moment globally. The same timestamp may display as morning in London, earlier in New York and later in Tokyo while still referring to the exact same instant.
JavaScript Date.now()
JavaScript Date.now() returns the number of milliseconds elapsed since the Unix epoch. The tool can convert that value directly when Milliseconds or Auto Detect is selected.
Common Mistakes
Avoid these common mistakes to achieve the most accurate results.
- Interpreting milliseconds as seconds.
- Interpreting seconds as milliseconds.
- Assuming a Unix timestamp contains timezone information.
- Treating a local date as UTC without intentionally converting it.
- Removing a timezone offset from an ISO date and assuming the instant remains unchanged.
- Assuming the same wall-clock time represents the same instant in every timezone.
- Ignoring daylight-saving transitions.
- Multiplying or dividing by 1000 more than once.
- Rounding milliseconds when exact sub-second precision matters.
- Assuming every system stores timestamps using Unix seconds.
- Assuming database timestamp columns necessarily contain Unix epoch numbers.
- Confusing ISO 8601 strings with Unix timestamps.
- Assuming JavaScript and PHP use the same default timestamp units.
- Using local server time when UTC was expected.
- Converting an ambiguous date without selecting the intended timezone.
Glossary
Definitions of the most important terms used by this tool.
Unix Timestamp
A numeric representation of an instant based on elapsed time from the Unix epoch at 00:00:00 UTC on 1 January 1970.
Unix Epoch
The reference instant 1970-01-01 00:00:00 UTC from which Unix time is measured.
Epoch Time
Another common name for Unix timestamp or Unix time.
Timestamp
A value representing a particular instant or date-time. The exact format and unit depend on the system using it.
Unix Seconds
The number of elapsed whole or fractional seconds from the Unix epoch.
Unix Milliseconds
The number of elapsed milliseconds from the Unix epoch, commonly used by JavaScript.
UTC
Coordinated Universal Time, the global time standard commonly used for timestamps and cross-system date calculations.
Timezone
A set of rules describing a region's local clock offset from UTC, including daylight-saving changes where applicable.
Timezone Offset
The difference between local clock time and UTC at a particular instant.
ISO 8601
An international standard for date and time representations, commonly used in APIs and software systems.
Z
A suffix used in ISO 8601 timestamps to indicate UTC, sometimes called Zulu time.
RFC Date
A textual date representation following an RFC-defined format, often used in internet protocols and HTTP-related contexts.
Date.now()
A JavaScript function returning elapsed milliseconds since the Unix epoch.
DateTimeImmutable
A PHP date-time class representing an immutable date and time value.
Epoch Milliseconds
Elapsed milliseconds from the Unix epoch, commonly used in JavaScript and some APIs.
Wall-Clock Time
A date and time as displayed in a particular timezone, such as 09:00 in Europe/London.
Relative Time
A description of a timestamp relative to another instant, such as 5 minutes ago or in 3 days.
Frequently Asked Questions
What is a Unix timestamp?
A Unix timestamp represents an instant using elapsed time from 00:00:00 UTC on 1 January 1970. Traditional Unix timestamps normally use seconds.
What is the Unix epoch?
The Unix epoch is 1 January 1970 at 00:00:00 UTC. Unix timestamps measure elapsed time relative to this instant.
What is epoch time?
Epoch time is another common name for Unix time or a Unix timestamp.
Are Unix timestamps in seconds or milliseconds?
Traditional Unix timestamps normally use seconds, but many platforms including JavaScript commonly use milliseconds. The tool supports both.
Why are JavaScript timestamps longer than Unix timestamps?
JavaScript commonly represents elapsed time in milliseconds, producing values roughly 1000 times larger than timestamps expressed in seconds.
What does Date.now() return?
JavaScript Date.now() returns elapsed milliseconds since the Unix epoch.
Does a Unix timestamp have a timezone?
No. A Unix timestamp identifies an instant. A timezone is applied only when formatting that instant as a local date and time.
Why does the same timestamp show different times in different locations?
The timestamp identifies one global instant, while each timezone displays that instant using its own local clock rules.
What is UTC?
UTC is the global time standard commonly used as the neutral reference for timestamps and date-time exchanges between systems.
What is ISO 8601?
ISO 8601 is a standardized date-time representation commonly used by APIs. An example UTC value is 2026-08-16T16:00:00Z.
What does Z mean at the end of a timestamp?
Z indicates that the ISO 8601 date-time is expressed in UTC.
How do I convert a timestamp to a date?
Enter the numeric timestamp, specify whether it uses seconds or milliseconds, and the converter will calculate the corresponding date and time.
How do I convert a date to a Unix timestamp?
Enter the calendar date and time together with the intended timezone. The converter then calculates the corresponding Unix seconds and milliseconds.
Why is timezone important when converting a date to a timestamp?
A wall-clock time such as 09:00 represents different instants in London, New York and Tokyo. The timezone determines which instant should be converted.
Does timezone matter when converting a timestamp to a date?
It affects how the timestamp is displayed, but not the underlying instant represented by the timestamp.
Can Unix timestamps represent dates before 1970?
Many modern systems support negative Unix timestamps representing instants before the Unix epoch, although platform support and range can vary.
Can Unix timestamps include fractions of a second?
Yes. Some systems use fractional seconds, milliseconds, microseconds or nanoseconds. This tool focuses on seconds and milliseconds.
What is the difference between Unix seconds and Unix milliseconds?
Unix seconds count seconds from the epoch, while Unix milliseconds count thousandths of a second. A millisecond timestamp is normally 1000 times the equivalent seconds value.
How can I tell whether a timestamp uses seconds or milliseconds?
Current timestamps in seconds are typically around ten digits, while milliseconds are usually around thirteen digits. Auto Detect can use this as a practical heuristic, but explicit units are more reliable.
Can daylight saving time change a Unix timestamp?
The timestamp itself identifies an instant and does not change. Daylight-saving rules can change how that instant is displayed in a local timezone and can affect date-to-timestamp conversions.
What timestamp format does Laravel use?
Laravel commonly works with date-time objects and formatted database timestamps rather than requiring raw Unix values, although PHP date-time objects can easily produce Unix seconds when required.
What timestamp format does JavaScript use?
JavaScript Date objects internally represent time using milliseconds from the Unix epoch.
Does SwiftVecto send timestamps or dates to the server?
The interactive Unix Timestamp Converter is designed to perform normal conversion and timezone display directly inside your browser.
Is the Unix Timestamp Converter free?
Yes. SwiftVecto provides this developer utility for converting between Unix timestamps, dates and common date-time formats.
Things to Know
- The tool supports timestamp-to-date and date-to-timestamp conversion.
- Timestamp input supports seconds, milliseconds and automatic unit detection.
- Traditional Unix timestamps are normally measured in seconds.
- JavaScript timestamps commonly use milliseconds.
- Unix timestamps represent instants independent of timezone.
- Timezone selection affects display and interpretation of wall-clock dates.
- ISO 8601 UTC output uses the Z suffix.
- Negative timestamps may represent dates before the Unix epoch when supported by the runtime.
- Auto Detect is intended as a convenience and explicit units remain more reliable.
- Normal interactive conversion is intended to happen directly inside the browser.
Disclaimer
Timestamp unit conventions differ between programming languages, databases and APIs, so developers should confirm whether seconds or milliseconds are expected.
Timezone and daylight-saving rules can affect wall-clock date interpretation.
Automatic timestamp-unit detection uses practical heuristics and should not replace explicit unit selection when precision matters.
Very large or very small timestamp values may exceed the supported date range of a browser or runtime.
Users remain responsible for testing date-time behaviour against the actual environment used by their application.
Official References
The following official resources were used when developing this tool and are useful for further reading.
MDN Web Docs - Date
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date
MDN Web Docs - Date.now()
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/now
PHP Documentation - DateTimeImmutable
https://www.php.net/manual/en/class.datetimeimmutable.php