FREE TOOL

DynamoDB Item Size Calculator & Capacity Simulator

Accurately calculate size of DynamoDB items and attributes with detailed explanations. Simulate table capacity based on item sizes.

  • Your data never leaves your browser: everything is calculated by JavaScript on this page, not on a server.
  • Nothing you enter is uploaded, processed on a server or stored. Check it in your browser's developer tools (Network tab).
  • Once the page has loaded, the tool works without an internet connection.

Item Size and Capacity

ITEM SIZE0 bytesMaximum size of single item is 409600 bytes
KEYS SIZE0 bytes
VALUES SIZE0 bytes
1 KB = 1024 bytes (binary)
ATTRIBUTES · SIZES IN BYTES · CLICK A COLUMN TO SORT
RCUs PER READ OF THIS ITEM
Eventual Consistency0 RCURead operations that may return stale data. Ideal for high throughput and low latency. Cost: 0.5 RCU per 4 KB read.
Strong Consistency0 RCURead operations that always return the latest data. Cost: 1 RCU per 4 KB read.
Transactional Read0 RCUACID-compliant read operations. Cost: 2 RCUs per 4 KB read.
WCUs PER WRITE OF THIS ITEM
Standard Write0 WCURegular write operations (PutItem, UpdateItem, DeleteItem). Cost: 1 WCU per 1 KB written.
Transactional Write0 WCUACID-compliant write operations. Cost: 2 WCUs per 1 KB written.
Calculation Explanation

Calculations are based on AWS guidelines related to item size and have been validated by empirical tests.

Table Capacity Simulation

Simulation is based on the previously calculated item size: 0 bytes

READS PER SECOND WITH 10 RCUs
Eventual ConsistencyInfinity / secCost: 0.5 RCU per 4 KB read.
Strong ConsistencyInfinity / secCost: 1 RCU per 4 KB read.
Transactional ReadInfinity / secCost: 2 RCUs per 4 KB read.
WRITES PER SECOND WITH 10 WCUs
Standard WriteInfinity / secCost: 1 WCU per 1 KB written.
Transactional WriteInfinity / secCost: 2 WCUs per 1 KB written.
Calculating RCUs and WCUs is a typical AWS Developer Associate exam questionTry free DVA-C02 practice questions with answers and explanations.DVA-C02 questions →

How the calculator works

Paste an item as plain JSON or DynamoDB JSON and the calculator shows:

  • the size of every attribute - its name and its value - and of the whole item;
  • the read and write capacity units (RCU and WCU) one read or write of the item consumes, for each kind of operation;
  • how many of those operations per second a table with the given provisioned RCU and WCU handles before requests get throttled.

It follows the rules AWS publishes for item sizes; where AWS gives none (the sets), it uses measured values. Everything runs in your browser. To convert an item between the two formats, use the DynamoDB JSON converter.

How item size is calculated in DynamoDB

An item's size is the sum of its attributes, and every attribute counts twice: the UTF-8 bytes of its name plus the size of its value. Type descriptors such as "S" do not count. Short attribute names save space in every item of the table.

TypeSize of the value
String SUTF-8 bytes of the string
Number N1 byte per two significant digits, plus 1 byte (about; leading and trailing zeros are trimmed)
Binary Braw bytes, not the length of the base64 text
Boolean BOOL, Null NULL1 byte
List L, Map M3 bytes, plus each element's size and 1 byte per element (a map element's size includes its name)
Sets SS, NS, BSNot documented by AWS; measured.the sum of the elements' sizes, with no overhead

String

Count UTF-8 bytes, not characters - they differ for anything outside ASCII:

{"id": {"S": "uniqueIdString"}}
id (2) + uniqueIdString (14) = 16 bytes

{"caféName": {"S": "Mocca"}}
caféName (9, "é" takes 2 bytes) + Mocca (5) = 14 bytes, not 13

In Node.js, Buffer.byteLength(text, 'utf8') gives the byte count.

Number

Count the significant digits - without leading and trailing zeros, the sign and the decimal point (002321 has four, 0.00200 has one) - take 1 byte per two of them rounded up, and add 1 byte. A negative number takes 1 more byte - measured, AWS does not document it.

{"id": {"N": "777"}}
id (2) + 777 (2) + (1) = 5 bytes

{"id": {"N": "7777"}}
id (2) + 7777 (2) + (1) = 5 bytes

Boolean and Null

{"isActive": {"BOOL": true}}
isActive (8) + (1) = 9 bytes

{"phoneNumber": {"NULL": true}}
phoneNumber (11) + (1) = 12 bytes

Binary

DynamoDB JSON carries binary data as base64, but the size counts the decoded bytes:

{"picture": {"B": "U29tZSBiaW5hcnkgZGF0YQ=="}}
picture (7) + "Some binary data" (16) = 23 bytes

List and Map

{"interests": {"L": [{"S": "Reading"}, {"S": "Traveling"}, {"N": "77"}]}}
interests (9) + (3) + Reading (7) + (1) + Traveling (9) + (1) + 77 (2) + (1) = 33 bytes

{"address": {"M": {
  "street": {"S": "Wall Street"},
  "city": {"S": "New York"},
  "state": {"S": "NY"},
  "zipCode": {"S": "12345"}
}}}
address (7) + (3)
  + street (6) + Wall Street (11) + (1)
  + city (4) + New York (8) + (1)
  + state (5) + NY (2) + (1)
  + zipCode (7) + 12345 (5) + (1) = 62 bytes

A map costs more than a list with the same values, because every element carries its name.

Sets

Measured: a set is the sum of its elements, each sized like a single value of its type, with no overhead.

{"interests": {"SS": ["Reading", "Traveling", "Cooking"]}}
interests (9) + Reading (7) + Traveling (9) + Cooking (7) = 32 bytes

{"favoriteNumbers": {"NS": ["7", "14", "21"]}}
favoriteNumbers (15) + 7 (2) + 14 (2) + 21 (2) = 21 bytes

{"preferences": {"BS": ["U29tZSBiaW5hcnkgZGF0YTE=", "U29tZSBiaW5hcnkgZGF0YTI="]}}
preferences (11) + "Some binary data1" (17) + "Some binary data2" (17) = 45 bytes

From item size to read and write capacity

Reads are rounded up to the next 4 KB and writes to the next 1 KB, so a 500-byte item costs as much as a 1 KB one. A 5 KB item takes:

OperationCost5 KB item
Eventually consistent read0.5 RCU per 4 KB1 RCU
Strongly consistent read1 RCU per 4 KB2 RCU
Transactional read2 RCU per 4 KB4 RCU
Standard write1 WCU per 1 KB5 WCU
Transactional write2 WCU per 1 KB10 WCU

Query rounds the total size of all the items it returns, so many small items are cheap to read together. BatchGetItem rounds every item on its own, like separate GetItem calls.

Frequently asked questions

Is it safe to paste production data?

Yes. The size is calculated in your browser: the item you paste is not uploaded, not processed on a server, not stored and not logged. The page only counts that the calculator was used, never what you pasted.

What is the maximum size of a DynamoDB item?

400 KB, attribute names and values together. Larger data belongs in Amazon S3, with its key in the item.

Do attribute names count towards the item size?

Yes, in every item. A 20-byte name in 10 million items takes about 200 MB of storage and counts towards the capacity of every read and write.

Why is my item bigger than its JSON?

Lists, maps and numbers add overhead bytes, and a string outside ASCII takes more bytes than it has characters. It can also be smaller: JSON quotes, brackets and type descriptors do not count.

References

DynamoDB item sizes and formats
DynamoDB read and write operations