Timestamp Converter
Current UNIX Timestamp
Timestamp → Date
Date → Timestamp
You can also type dates like "2024-01-01 12:00:00"
About Timestamp Converter
A UNIX timestamp is the number of seconds (or milliseconds) that have elapsed since January 1, 1970 00:00:00 UTC (the Unix Epoch). Timestamps are widely used in programming, databases, and APIs to represent dates and times in a standardized, timezone-independent format. This tool converts between UNIX timestamps and human-readable dates in both directions. It supports both seconds and milliseconds, displays dates in multiple formats (ISO 8601, UTC, local time), shows relative time (e.g., '3 hours ago'), and provides real-time updates of the current timestamp. Perfect for debugging timestamps, converting between formats, understanding date calculations, and working with APIs. All conversions happen in your browser for complete privacy.
How to Use
- See the current UNIX timestamp at the top (updates every second).
- To convert a timestamp to date: Enter a timestamp on the left, choose seconds or milliseconds, and see multiple date formats.
- Click the refresh icon to use the current timestamp.
- To convert a date to timestamp: Enter or select a date/time on the right using the picker.
- Click the refresh icon to use the current date/time.
- Or type dates in formats like "2024-01-01" or "2024-01-01 12:00:00".
- View the converted timestamp in both seconds and milliseconds.
- Click any copy icon to copy that value to your clipboard.
- Use "Clear All" to reset both converters.
Frequently Asked Questions
What is a UNIX timestamp?
A UNIX timestamp is the number of seconds that have elapsed since the Unix Epoch: January 1, 1970 00:00:00 UTC. It's a standard way to represent dates and times as a single number, making it easy to store, compare, and calculate time differences across different systems and timezones.
Seconds vs Milliseconds - which should I use?
Unix timestamps are traditionally in seconds, which is what most Unix/Linux systems use. JavaScript uses milliseconds (Date.now() returns milliseconds). Choose based on your use case: seconds for Unix systems, databases like PostgreSQL; milliseconds for JavaScript, some APIs, and when you need sub-second precision.
Why do I see different dates in different formats?
Timestamps represent a specific moment in time globally, but how they display depends on timezone and format. ISO 8601 shows UTC time with 'Z'. UTC format shows GMT time. Local format uses your browser's timezone. All represent the same moment, just displayed differently.
What is the Unix Epoch?
The Unix Epoch is January 1, 1970 00:00:00 UTC. This arbitrary date was chosen as the starting point for Unix time. All Unix timestamps represent the number of seconds/milliseconds since this moment. Negative timestamps represent dates before the epoch.
Can I convert dates before 1970?
Yes! Dates before January 1, 1970 are represented as negative timestamps. For example, January 1, 1969 is -31536000 seconds. However, very old dates (before 1900) may have accuracy issues due to historical calendar changes and system limitations.
What is ISO 8601 format?
ISO 8601 is an international standard for date/time representation: YYYY-MM-DDTHH:mm:ss.sssZ. The 'T' separates date and time, and 'Z' indicates UTC timezone (Zulu time). Example: 2024-01-15T14:30:00.000Z. It's widely used in APIs and data exchange because it's unambiguous and sortable.
How do I handle timezones?
Timestamps are timezone-agnostic—they represent a single moment in time globally. When displaying, different timezones show different local times for the same moment. Store timestamps in your database, convert to local time only when displaying to users. This tool shows both UTC and your local timezone.
What does "relative time" mean?
Relative time shows how long ago (or until) a timestamp occurred, like "3 hours ago" or "in 2 days". It's useful for social media posts, comments, and activity feeds. The relative time is calculated from the current moment and updates as time passes.
Why is my timestamp not converting correctly?
Check if you're using the right unit (seconds vs milliseconds). If the date seems way off, try switching units. Very large numbers are usually milliseconds. Also verify the timestamp is within a reasonable range (1970-2100). Invalid or out-of-range timestamps will show an error.
Is this tool accurate?
Yes, this tool uses JavaScript's native Date object which handles all timezone conversions and date calculations accurately. The current timestamp updates every second. All conversions happen in your browser, and results are as accurate as your system clock.