# ULID / NanoID / KSUID / Snowflake ID Decoder

Decode lexically sortable IDs losslessly with BigInt: ULID (Crockford base32), KSUID (base62), NanoID, MongoDB ObjectId, and Discord/Twitter/Sonyflake Snowflakes — with ISO timestamps, raw hex, bit-level field breakdowns and birthday-bound collision probabilities.

> Canonical page: https://elysiatools.com/en/tools/ulid-nanoid-ksuid-snowflake-id-decoder

- **Category:** Development

- **Keywords:** ulid decoder, ksuid decoder, nanoid, snowflake decoder, objectid, crockford base32, collision probability

## Overview

ULID: 48-bit millisecond timestamp + 80-bit randomness across 26 Crockford base32 characters. KSUID: 32-bit second timestamp since epoch 2014-05-13T16:53:20Z + 128-bit payload across 27 base62 characters. Snowflakes decode through the shared snowflake decoder library with platform epochs. Collision estimates use the birthday bound p ≈ 1 − e^(−n(n−1)/2·2^bits). Verified against the ULID spec example, the segmentio/ksuid README example, and ulid npm round-trips.

## Inputs

- **IDs (one per line)** (textarea): 01ARZ3NDEKTSV4RRFFQ69G5FAV 0ujtsYcgvSTl8PAuAdqWYSMnLOv 175928847299117063
- **Format** (select)
- **Collision estimate (IDs generated)** (number): Number of IDs assumed generated inside one time window when estimating collision probability.

## When to use

- Identify an unfamiliar ID format and inspect its encoded fields.
- Extract creation timestamps from ULIDs, KSUIDs, ObjectIds, or supported Snowflake IDs.
- Estimate collision probability for generated IDs using a specified count.

## How it works

- Paste one or more IDs into the IDs field, with one ID on each line.
- Choose Auto-detect or pin the format to ULID, KSUID, NanoID, ObjectId, or a supported Snowflake type.
- The decoder analyzes each ID with BigInt-based parsing and shows format-specific fields such as timestamps, randomness, payloads, or Snowflake bit segments.
- Set Collision estimate (IDs generated) to calculate a birthday-bound collision estimate for the relevant identifier space.

## Use cases

- Debug ID generation by verifying timestamps, hexadecimal values, and encoded bit fields.
- Investigate records and events by recovering time information from sortable IDs.
- Compare identifier designs by reviewing entropy and estimated collision resistance.

## Frequently asked questions

### Which ID formats can this decoder analyze?

It supports ULID, KSUID, NanoID, MongoDB ObjectId, and Discord, Twitter, and Sonyflake Snowflake IDs.

### Can I decode multiple IDs at once?

Yes. Enter one ID per line in the IDs field.

### Does a NanoID contain a timestamp?

No. NanoID has no timestamp component, so the tool reports its URL-safe alphabet and entropy instead.

### Which Snowflake format should I select?

Select Discord, Twitter, or Sonyflake according to the system that generated the ID. Auto-detection may identify the numeric form, but the platform epoch matters for timestamp decoding.

### How is collision probability estimated?

The tool uses a birthday-bound approximation based on the number of generated IDs and the available random or payload bits.

## Related tools

- [NTP RFC 5905 / SNTP Leap Second & Epoch Decoder](https://elysiatools.com/en/tools/ntp-rfc-5905-sntp-leap-second-epoch-decoder): Decode an NTP/SNTP 48-byte packet: LI/VN/Mode bitfield, stratum, poll, precision, root delay/dispersion, reference ID (with clock & kiss codes), and four 64-bit 1900-epoch timestamps
- [Snowflake / Discord ID Bit Decoder](https://elysiatools.com/en/tools/snowflake-discord-id-bit-decoder): Decode 64-bit Snowflake-style IDs for Discord, Twitter, Mastodon, Sonyflake, Instagram, or a custom bit profile. Extract timestamp, worker/process/machine, sequence fields, align platform epochs, and infer a Discord shard when a shard count is supplied.
- [Modern Unique ID Generator](https://elysiatools.com/en/tools/uid-generator): Generate modern unique identifiers: ULID, NanoID, Snowflake and CUID2. Compare formats, decode ULID timestamps and pick the right ID for your system.
- [JavaScript Deobfuscator](https://elysiatools.com/en/tools/javascript-deobfuscator): Deobfuscate and analyze obfuscated JavaScript code to improve readability and understanding
- [Avro Converter](https://elysiatools.com/en/tools/avro-converter): Encode and decode data to/from Avro data serialization format with schema support
- [Base32 Converter](https://elysiatools.com/en/tools/base32-converter): Encode and decode text to/from Base32 format with multiple variants
- [Base58 Converter](https://elysiatools.com/en/tools/base58-converter): Encode and decode text to/from Base58 format with Bitcoin and Ripple variants
- [Base62 Converter](https://elysiatools.com/en/tools/base62-converter): Encode and decode text to/from Base62 format (0-9, A-Z, a-z)

## Samples

- [Android Image Processing Java Samples](https://elysiatools.com/en/samples/android-image-processing-java): Android Java image processing examples including reading/saving images, scaling, and format conversion
- [Android Image Processing Kotlin Samples](https://elysiatools.com/en/samples/android-image-processing-kotlin): Android Kotlin image processing examples including reading/saving images, scaling, and format conversion
- [Web Image Processing Python Samples](https://elysiatools.com/en/samples/web-image-processing-python): Web Python image processing examples using PIL/Pillow including reading, saving, resizing, and format conversion
- [Web Image Processing Rust Samples](https://elysiatools.com/en/samples/web-image-processing-rust): Web Rust image processing examples including image read/save, scaling, and format conversion

## Related content

- [Text Redaction, Highlighting, and Presentation Formatting Tools](https://elysiatools.com/en/hubs/text-format): Compare tools for masking sensitive text, finding PII, normalizing phone numbers, highlighting phrases, centering text, and formatting diffs in one hub.
- [JSON Formatting, Diff, and Normalization Tools](https://elysiatools.com/en/hubs/json-format): Compare JSON formatting, diffing, log review, config comparison, and data-normalization tools in one hub for readable and reviewable JSON workflows.
- [Code and Markup Minify, Beautify, and Format Tools](https://elysiatools.com/en/hubs/code-minify-beautify-format-tools): Minify and beautify CSS, HTML, JavaScript, JSON, SQL, XML, YAML, TOML, SVG, and VBA, lint Markdown and email HTML, and format code across languages in one hub for production and review workflows.
