Trexmi
Developer Ready

JSON Pointer Tester

Resolve an RFC 6901 JSON Pointer against an object or array, including escaped slash and tilde characters, and inspect the selected value.

Resolve object properties and array indexes Treat an empty pointer as the document root Decode ~0 as tilde and ~1 as slash Reject invalid escape sequences
INPUT Developer source value *
0 chars0 words0 lines
Paste the source value for this specific transformation. Example: {"user":{"name":"Ada"},"items":[1,2]}

Tool settings

Ctrl / ⌘ + Enter
Resolved value Resolved pointer and JSON value.
About the tool

What JSON Pointer Tester does

JSON Pointer Tester resolves one RFC 6901 pointer against a JSON document and returns the exact referenced value. Object property names and zero-based array indexes are processed one token at a time. An empty pointer selects the entire document.

A pointer is not a search query. Each token must identify one property or array position at the current level. Literal slash and tilde characters inside property names use the RFC escape sequences ~1 and ~0. The tool reports invalid escapes, absent properties, non-canonical array indexes, and attempts to continue through scalar values.

JSON Pointer Tester resolving an RFC 6901 path
Resolve a precise pointer and compare the selected value with the source document.

How to use

  1. Add the document. Paste valid JSON containing the real object and array structure you need to navigate.
  2. Write the pointer. Start each reference token with a slash. For example, /users/1/name selects a nested array item property.
  3. Escape special names. Write a slash in a property name as ~1 and a tilde as ~0.
  4. Resolve the value. Run the tool and inspect the returned JSON value or the exact failure message.
  5. Check edge cases. Test an empty pointer, missing fields, empty arrays, and the largest expected index.
Built for the task

Why use JSON Pointer Tester?

Focused controls, predictable output, and a workflow designed around this exact transformation.

01

Exact RFC path

Resolve one unambiguous property or array position instead of searching the complete document.

02

Escape handling

Test property names containing literal slash and tilde characters with RFC 6901 encoding.

03

Actionable failures

Distinguish malformed pointers, missing properties, bad indexes, and scalar traversal.

04

Any JSON value

Return the selected object, array, string, number, boolean, or null value.

Useful answers

Questions about JSON Pointer Tester

Practical details about input, output, privacy, limits, and the best way to use this tool.

01 What is a JSON Pointer?

JSON Pointer is the RFC 6901 syntax for identifying one value inside a JSON document using slash-separated reference tokens.

02 What does an empty pointer select?

An empty pointer selects the complete JSON document. It is different from /, which selects an object property with an empty name when that property exists.

03 How do I reference a property containing a slash?

Replace each literal slash in a reference token with ~1. For example, property a/b is written as /a~1b.

04 How do I reference a property containing a tilde?

Replace each literal tilde with ~0. Decoding processes ~1 and ~0 according to RFC 6901.

05 Are array indexes zero-based?

Yes. Index 0 selects the first item. A leading zero such as 01 is rejected, and the index must exist in the current array.

06 Can I use the hyphen token to append an array item?

No. The hyphen has update semantics in JSON Patch, but it does not identify an existing array value for this read-only resolver.

07 Does this tool evaluate JSONPath expressions?

No. Wildcards, filters, recursive descent, slices, and unions belong to JSONPath. Use JSON Path Finder when you need to locate matching keys or values.

08 Does the tester support URI fragment pointers beginning with #?

No. Enter the JSON string representation described by RFC 6901, such as /users/0, not a percent-encoded URI fragment such as #/users/0.

Learn JSON

Read the complete JSON Guide

Learn JSON objects, arrays, value types, validation, formatting, parsing, API workflows, and common syntax errors.

  • Objects, arrays, and values
  • Validation and formatting
  • API and parsing workflows
Read guide Practical explanations and examples

Examples

Select a property from an array item

Array indexes are zero-based, so token 1 selects the second user.

Input
JSON: {"users":[{"name":"Ada"},{"name":"Lin"}]}
Pointer: /users/1/name
Output
{"pointer":"/users/1/name","value":"Lin"}

Escape slash and tilde in property names

The reference token a~1b becomes a/b, and ~0key becomes ~key.

Input
JSON: {"a/b":{"~key":42}}
Pointer: /a~1b/~0key
Output
{"pointer":"/a~1b/~0key","value":42}

Select the complete document

The empty JSON Pointer is the root; a slash alone would instead select a property whose name is empty.

Input
JSON: {"ready":true,"items":[]}
Pointer: (empty)
Output
{"pointer":"","value":{"ready":true,"items":[]}}

Reject a non-canonical array index

RFC array index tokens use 0 or a positive integer without a leading zero.

Input
JSON: {"items":["a","b"]}
Pointer: /items/01
Output
Error: JSON Pointer array index cannot contain a leading zero.

RFC 6901 pointer syntax

The empty string references the complete document. Every non-empty pointer starts with /, and each following token selects one child of the current value. Object tokens match property names exactly. Array tokens are zero-based indexes written without leading zeros, except for the index 0 itself.

JSON object keys that look numeric remain object property names. A token becomes an array index only when the current value is an array. Resolution stops with an error if a token is absent or the current value is a string, number, boolean, or null.

Escaping slash and tilde characters

Inside a reference token, ~1 represents a literal slash and ~0 represents a literal tilde. For a document shaped like {"a/b":{"~key":42}}, the pointer is /a~1b/~0key. Any other tilde escape, such as ~2, is invalid.

Why a valid pointer can still fail

Pointer syntax and successful resolution are separate checks. A syntactically valid pointer can name a property that is absent, an index outside the array, or a deeper token after a scalar. Test every pointer against representative document versions when optional fields or arrays can change.

JSON Pointer Tester limits

This is a read-only resolver for the JSON string representation in RFC 6901. It does not evaluate URI fragment identifiers beginning with #, JSONPath queries, JSON Patch operations, wildcards, filters, or relative JSON Pointer proposals. The JSON parser also cannot preserve multiple duplicate object names as distinct addressable entries.

The token - cannot resolve an existing array element. Some JSON Patch operations use it as a position for appending, but that behavior is outside JSON Pointer value lookup.

Related indexed Trexmi tools

Use JSON Path Finder to locate matching keys or values, JSON Validator to repair parse errors, and JSON Formatter to make deeply nested input easier to inspect.

Official specification

For normative syntax, escaping, evaluation, and error behavior, read RFC 6901: JavaScript Object Notation (JSON) Pointer.