EpochTools
Backend

Unix Timestamps in Python

Standard library time and datetime modules with timezone awareness.

Complete Python Recipe

import time
from datetime import datetime, timezone

# 1. Current timestamp in seconds
current_sec = int(time.time())
current_ms = int(time.time() * 1000)

# 2. Convert timestamp (1710000000) to datetime object (UTC)
dt = datetime.fromtimestamp(1710000000, tz=timezone.utc)
print(dt.isoformat()) # YYYY-MM-DDTHH:MM:SS+00:00

# 3. Convert datetime back to timestamp
epoch_val = int(dt.timestamp())

Test With Live Converter

Epoch → Human Date

Paste any Unix timestamp. The unit is auto-detected from its magnitude.

Auto-detects seconds, milliseconds, microseconds, or nanoseconds. Example: 1735689600

Detected:Auto (Seconds)

UTC ISO 8601

–

Local — auto

–

RFC 2822 / GMT

–

Seconds Value

–

Relative Time

–