DynamoDB Query Formatter Online — Format & Beautify DynamoDB Params
Paste your AWS DynamoDB params above and get clean, properly indented JSON back, with every value left exactly as you wrote it. Handles Scan, Query, PutItem, UpdateItem, and DeleteItem params — all processed in your browser.
How to Format DynamoDB Params — Step-by-Step
Input Your DynamoDB Params
Got a compact DynamoDB params object from your AWS SDK code, logs, or documentation? Paste it in — the formatter handles plain JSON, variable assignments (const params = ...), and SDK command wrappers like new ScanCommand(...).
.json or .js fileExample: Compact DynamoDB Scan Params
A typical one-liner you might copy from your codebase or logs:
// Compact params from your code { "TableName": "Orders", "FilterExpression": "#status = :s AND #total > :min", "ExpressionAttributeNames": { "#status": "orderStatus", "#total": "totalAmount" }, "ExpressionAttributeValues": { ":s": { "S": "SHIPPED" }, ":min": { "N": "50" } } }
Automatic Formatting & Validation
The formatter parses your JSON and outputs it with proper 2-space indentation, making FilterExpression, ExpressionAttributeNames, and typed attribute values easy to read. If the JSON is broken, the output names the line and column of the first problem, for example a trailing comma or a key without double quotes.
Formatted Output
The same params from Step 1, now with clean 2-space indentation:
{ "TableName": "Orders", "FilterExpression": "#status = :s AND #total > :min", "ExpressionAttributeNames": { "#status": "orderStatus", "#total": "totalAmount" }, "ExpressionAttributeValues": { ":s": { "S": "SHIPPED" }, ":min": { "N": "50" } } }
Minify for Configuration
Need compact JSON for environment variables, AWS CLI commands, or CI/CD pipeline config files? Click "Minify" to put the params on a single line with the spaces between keys and values removed (spaces inside strings stay). This is especially useful when storing DynamoDB params in .env files or passing them as string arguments.
Minified Output
The same params compressed to a single line:
{"TableName":"Orders","FilterExpression":"#status = :s AND #total > :min","ExpressionAttributeNames":{"#status":"orderStatus","#total":"totalAmount"},"ExpressionAttributeValues":{":s":{"S":"SHIPPED"},":min":{"N":"50"}}}Copy or Download
.json file for version control or sharingFrequently Asked Questions — DynamoDB Query Formatter
How do I format DynamoDB params online?
Paste the params into the input editor. About half a second after you stop typing, the output shows them with 2-space indentation, and if the JSON is broken you get the line and column of the problem instead. You can paste plain JSON, a const params = {...} assignment, an SDK call such as new ScanCommand({...}), or the JSON part of an AWS CLI --cli-input-json argument. Upload works for .json, .js and .txt files, and Sample loads a Scan request to try it on.
Does it handle variable assignments and SDK commands?
Yes. The params object is picked out of const params = {...};, new QueryCommand({...}) or await client.send(new ScanCommand({...})), and // or /* */ comments around it are skipped (a // inside a string, like a URL, is left alone). One thing it won't do is rewrite JavaScript: the object itself has to be JSON, with keys and strings in double quotes. If you paste TableName: 'users', the error points at the first key that needs quotes.
Can I minify DynamoDB params?
Yes. Minify puts the whole object on one line with no spaces between tokens, which suits environment variables, CI config values and AWS CLI arguments. Spaces inside strings, such as a FilterExpression, are kept. As soon as you edit the input again, the output goes back to the formatted view.
What is the difference between this and a regular JSON formatter?
A plain JSON formatter stops at the first line of const params = new ScanCommand(...), because that line isn't JSON. This page looks past the code and comments around your params and formats only the object. Inside the object nothing is special-cased: ExpressionAttributeValues, typed values like {"S": "active"} and nested BatchWriteItem lists are simply re-spaced. It doesn't check whether your expressions, attribute names or table exist; DynamoDB tells you that when the request runs.
Will formatting change any of my values?
No. The params are re-spaced as text rather than parsed into numbers and printed again. A number attribute like {"N": "8901240544102066246"} stays a string with every digit, a bare 14.50 stays 14.50, escapes such as \u0041 are left as written, and a key that appears twice stays twice.
Which DynamoDB operations does it support?
Any request whose params are written as JSON: Scan, Query, GetItem, PutItem, UpdateItem, DeleteItem, BatchGetItem, BatchWriteItem, TransactWriteItems, and ExecuteStatement for PartiQL. A bare PartiQL statement like SELECT * FROM users is not JSON, so paste the ExecuteStatement params instead, for example {"Statement": "SELECT * FROM users WHERE pk = ?"}. Strings inside the statement are never touched.
Is my data sent anywhere?
No. Formatting and minifying happen in your browser; the params you paste aren't uploaded and nothing is kept, so a reload starts with an empty editor. There's no account to create either.
Working with other query formats? Try the MongoDB Query Formatter, convert SQL queries to DynamoDB, or go the other way with DynamoDB to SQL and DynamoDB to MongoDB. For JSON that isn't DynamoDB params, the JSON Formatter is the better fit.
Related Tools
SQL to MongoDB
Convert SQL queries to MongoDB query syntax with aggregation pipeline support
MongoDB to SQL
Convert MongoDB queries and aggregation pipelines to equivalent SQL statements
SQL to DynamoDB
Convert SQL queries to AWS DynamoDB query and scan operations with PartiQL support
DynamoDB to SQL
Convert AWS DynamoDB query and scan operations to equivalent SQL statements
MongoDB Query Formatter
Format, beautify, and validate MongoDB queries with proper indentation and syntax highlighting
MongoDB to DynamoDB
Convert MongoDB queries to AWS DynamoDB query operations and vice versa