Unix Timestamp Converter

Convert Unix epoch timestamps to human-readable dates or convert local date and time values to epoch seconds.

Runs locally in your browser
Unix timestamp converter
Current Unix timestamp
Browser local time

Timestamp to date and time

Unix timestamp
Browser local time

Date and time to timestamp

Browser local time
Unix timestamp

Unix timestamp conversion reference

A Unix timestamp counts elapsed seconds from 1970-01-01 00:00:00 UTC. This page interprets date and time input in the browser's local time zone.

Store timestamps in UTC. Apply a named IANA time zone, including daylight-saving rules, only when displaying a value to a user.

Unix timestamp examples by environment
EnvironmentCurrent timestampConvert timestamp to UTC date and time
JavaScriptMath.floor(Date.now() / 1000)new Date(timestamp * 1000).toISOString()
Pythonint(time.time())datetime.fromtimestamp(timestamp, timezone.utc)
PHPtime()(new DateTimeImmutable("@$timestamp"))->setTimezone(new DateTimeZone("UTC"))
JavaInstant.now().getEpochSecond()Instant.ofEpochSecond(timestamp)
Gotime.Now().Unix()time.Unix(timestamp, 0).UTC()
RubyTime.now.to_iTime.at(timestamp).utc
PostgreSQLSELECT EXTRACT(EPOCH FROM NOW())::bigint;SELECT TO_TIMESTAMP(timestamp) AT TIME ZONE 'UTC';
MySQLSELECT UNIX_TIMESTAMP();SELECT FROM_UNIXTIME(timestamp);
Recent tools: