Send us translation corrections, feature suggestions and bug reports.Contact: toolsintab@gmail.com

XPath extractor

Getting ready…

XPath extractor User guide

Extract XML nodes, attributes and text using XPath.

Instructions

  1. Enter XML and XPath, for example //item/text().
  2. For namespaced XML, map prefixes to URIs as JSON, then query the path.
  3. Review matching elements, attributes, text or computed values, then save JSON or TXT.

Example

Input / settings

<item>A</item> · //item/text()

Result / checks

A

For example, {"a":"urn:example"} allows //a:item. A default namespace also needs an explicit query prefix.

Please note

XML → JSON / TXT

  • For example, {"a":"urn:example"} allows //a:item. A default namespace also needs an explicit query prefix.
  • This uses the browser XPath implementation. DTDs and external entities are rejected; correct XML syntax errors first.
  • Files and entered content are processed in this browser. Save results before closing the page.