Skip to content
toolgrid

No tool found. Try another word.

XML Tree Viewer

View XML as a collapsible tree with elements, attributes and text. Search the document and copy the XPath of any node.

Path

Runs in your browser. What you enter is kept for 30 days to improve Toolgrid, then deleted.

How to use the XML Tree Viewer

  1. 1 Paste XML or open an .xml file.
  2. 2 Expand and collapse elements, or search for a name or value.
  3. 3 Click a node to see and copy its XPath or value.

About the XML Tree Viewer

The XML tree viewer turns an XML document into a tree you can browse: elements with their children, attributes shown as @name, text content and comments. Elements with a single text value show that value right next to their name.

Click a node to get its path in XPath notation, such as /catalog/book[2]/title, with a position when an element occurs more than once. Copy it for use in XSLT, scripts or XPath tools.

The document is checked by your browser's XML parser, so malformed XML (a missing closing tag, an unescaped &) is reported with the line and column of the error. Namespaced names are shown with their prefix.

Frequently asked questions

What is an XPath?

A path to a node in an XML document, like /catalog/book[1]/@id for the id attribute of the first book element.

Why does my XML not load?

It is not well-formed. The error message shows the line; check for unclosed tags, & without amp; and quotes around attribute values.

Can it open SVG, RSS or sitemap files?

Yes, all of them are XML. Open the file or paste its content.

Are comments shown?

Yes, as #comment nodes. Whitespace between elements is left out.