MongoDB ObjectId Decoder

Canonical ObjectId
507f1f77bcf86cd799439011
Embedded timestamp
Unix (seconds): 1350508407ISO 8601 (UTC): 2012-10-17T21:13:27.000ZLocal time: 10/17/2012, 9:13:27 PM
Component bytes
Timestamp (4 bytes): 507f1f77Random (5 bytes): bcf86cd799Counter (3 bytes): 439011 (4427793)
Decoded locally in your browser by parsing the 12 ObjectId bytes. Nothing is generated or sent anywhere — your ObjectId stays only on this page.

Read a MongoDB ObjectId's embedded creation timestamp

A MongoDB ObjectId is 12 bytes shown as 24 hexadecimal characters: the first 4 bytes are a big-endian Unix-second creation timestamp, the next 5 bytes are a per-process random value, and the last 3 bytes are an incrementing counter. Because the timestamp leads, ObjectIds sort roughly by creation time, which is why pasting an _id answers “when was this document created?” without a Mongo shell. This tool only reads the bytes already in the identifier; to create one, use the ObjectId generator.