What is the precision of transaction IDs in Ledger?
Last updated: May 19, 2025
Ledger uses a 64-bit unsigned integer format for all transaction IDs. This means:
Transaction IDs range from 0 to 18,446,744,073,709,551,615
The format is fixed and consistent across all implementations
Storage Considerations
When storing transaction IDs in your own database:
Use a 64-bit unsigned integer field type (e.g., BIGINT UNSIGNED in MySQL)
Ensure your database and application can handle unsigned 64-bit integers
Note: While the 64‐bit format is exceptionally large for most use cases, our internal tests on PostgreSQL have indicated that performance can start to wane when handling datasets with well over a billion transactions. This is something we're actively monitoring as we continue to optimize and ensure Ledger performs efficiently even as transaction volumes increase.