XML viewer and formatter for Mac

View and format XML locally on Mac

XML Lens is a native macOS XML viewer and formatter for opening, reading, searching, and editing XML without uploading documents to a web formatter. It combines syntax-highlighted source, a synchronized structure tree, an inspector, and readable formatting in one workspace.

A clearer way to read XML

Open an XML file, paste XML from the clipboard, type directly, or drag a document into XML Lens. The editor and expandable tree stay synchronized so you can move from a node, attribute, or namespace to the corresponding source.

  • Syntax-highlighted XML editor with breadcrumbs
  • Structure tree for parent-child navigation
  • Node inspector with attributes, values, and generated XPath
  • Search tags, attributes, and values with previous/next match controls

Format for review, minify for payloads

Pretty-print compressed XML when you need to review it, or minify it when a compact payload is more useful. Comment removal and Compact for API or Readable for review presets keep common cleanup tasks close to the document.

  • Formatting and minification happen locally
  • Text zoom supports Command-Plus, Command-Minus, and Command-Zero
  • Dark, Light, Ocean, Forest, and Sepia themes are available

What XML Lens is—and is not

XML Lens supports macOS 14.0 or later and is currently version 1.8. It is a focused desktop viewer/editor, not an online XML validator or a browser-based collaborative editor; document processing stays on the Mac.