JSON Patch Applier

Run an RFC 6902 JSON Patch against a JSON document: add, remove, replace, move, copy and test, addressing values with RFC 6901 JSON Pointers. Every operation is applied to a copy, so a failing test or a bad pointer leaves the original untouched.

Choose Apply patch to run every operation in order and see the patched document.

A JSON Patch is an ordered array of operations, each with an op and a path; move and copy also need from, and add, replace and test need value. Pointers start with /, address array elements by index, use - to append in an add, and escape ~ as ~0 and / as ~1. Operations are atomic here: the document is copied first, and the first failure stops the run with the exact operation. Everything runs locally in your browser.