Set an object field to a new value.
Section: Filters and Conditions
Update field value
bash
bash
echo '{"name":"alice","age":30}' | jq '.age = 31'Explanation
Assignment lets you modify existing JSON structures.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Filters and Conditions