ToolXkit Icon

XML Viewer

Open and read an XML file in your browser, with the tags neatly indented.

  • Free
  • No signup
  • Nothing uploaded
  • No watermark

Source

0 lines
1

Tree

Paste something on the left, or press Sample to load an example.

Read in this tab. Nothing you paste or open is ever uploaded.

How to View an XML File Online

XML Viewer: before and after XML A BEFORE XML VIEWER XML A AFTER

XML turns up in RSS feeds, sitemaps, invoices, Android layouts and many older business systems. It is readable in principle, but a long file of nested tags quickly becomes hard to follow. This viewer checks the XML with your browser’s own parser and shows it as a tree of elements you can fold and unfold.

Open or drop a file, or paste the text. Tag names, attributes and their values are coloured differently, and short text content is shown beside its tag. If the file is not well-formed, the problem is flagged on the line where it happens.

No software to install Free Works on any device

Steps to Read XML as a Tree

  1. 1. Open the XML

    Use Open file for an .xml, .svg or .rss document, or drop one on the editor, or paste the markup. Sample shows a small order record.

  2. 2. Browse the elements

    The Tree pane lists each element with its attributes. Click one with children to open or close it; closed elements say how many child nodes they hold.

  3. 3. Tidy the source

    Format indents the markup neatly; Minify removes the spacing between tags. Expand all and Collapse all control the whole tree.

  4. 4. Fix errors

    An unclosed tag or stray ampersand is reported with its line number. Once you mend it on the left, the tree appears.

No .xml file to hand? Download a sample XML file (2.2 KB) and try it.

Try it now

What Is an XML File?

XML, the Extensible Markup Language, stores data as nested tags that you name yourself, such as <order> and <item>. Unlike HTML, the rules are strict: every tag must close, attribute values must be quoted and there must be a single root element. A file that follows these rules is called well-formed, and that is what this viewer checks.

Why Use an Online File Viewer?

Not every computer has the right program for a YAML, VCF, SRT or log file, and installing one just to look inside is a chore. A viewer opens the file in your browser and shows it neatly next to its source text.

“Sometimes you just need to see what is inside the file.”
  • No software to install
  • Data laid out as tables
  • Subtitles shown with timings
  • Code tried out in the page
  • Colour-coded source text
  • Contacts and calendars readable
  • Works on shared computers
  • Private files stay local

Popular Uses for Code and Data Viewers

People open these when a file arrives and nothing on the computer will show it.

  • Checking a JSON response Open a JSON or YAML file as a readable tree instead of one long line.
  • Reading contact backups See the names and numbers inside a VCF file exported from a phone.
  • Opening calendar invites Read the date, time and place in an ICS file before adding it.
  • Checking subtitles View SRT or VTT subtitles with their timings to spot a missing line.
  • Reading log files Scroll through a server or app log with the lines laid out clearly.
  • Previewing CSV and TSV Look at a data file as a table without opening a spreadsheet program.
  • Trying a code snippet Run a short Python or JavaScript example from a tutorial and see the output.
  • Viewing SVG graphics See how an SVG icon or drawing looks next to the markup behind it.

What the XML Viewer Includes

Element tree

Nested elements shown with indentation, and the first three levels open when the file loads.

Coloured attributes

Tag names, attribute names and attribute values each have a distinct colour for quick scanning.

Well-formed check

The browser’s built-in XML parser reads the file and reports the first error with its line.

Format and Minify

Re-indent messy markup or compress it, then copy or download the result.

Several file types

Accepts .xml, .svg and .rss files, plus anything you paste as text.

Why Use ToolXkit for XML Viewer?

Your files stay with you

Everything runs inside your browser. Nothing you open or type is uploaded to a server.

File Viewers for Different Users

Developers

Inspect config, env and data files on any machine without an editor installed.

Programming students

Try small programs in Python, JavaScript or SQL without setting anything up.

IT support staff

Open logs, HAR files and settings files that users send in.

Office workers

Read contact, calendar and CSV files that arrive as email attachments.

Video editors

Check subtitle files for timing and text before a video goes out.

Data analysts

Glance at CSV, TSV, JSONL and GeoJSON files before loading them anywhere.

Best Times to View a File Online

A browser viewer is handy when you are:

  • Using a borrowed or office computer
  • Opening an unfamiliar attachment
  • Checking a file before importing it
  • Learning to code without installing
  • Debugging a settings file
  • Proofreading subtitle timings
  • Looking inside a phone backup
  • Reviewing a server log

Tips for Checking XML

  1. An ampersand on its own inside text breaks XML. Replace each one with &amp; and the parser stops complaining.

  2. Tag names are case sensitive in XML. <Item> must close with </Item>, not </item>.

  3. Checking a sitemap? Paste it here to be sure it is well-formed before submitting it to a search engine.

  4. Collapse all first on a big file, then open only the branch you care about.

Frequently Asked Questions

Answers to common questions about this tool.

How do I open an XML file in a readable format?

Load it here using Open file, or let go of it over the editor. The right pane shows a tidy tree of elements and attributes, and Format re-indents the source on the left so both views are easy to read.

Does this validate XML against a schema?

No. Its job is the well-formed test: tags close properly and the syntax holds together. Validation against an XSD or DTD schema, which checks which elements are allowed, is a separate step.

Can I view SVG or RSS files?

Yes. SVG images and RSS feeds are XML underneath, so they open as a tree here. That is useful for finding a path or a feed item without reading raw markup.

Why does it say my XML has an error?

Common causes are an unclosed tag, mismatched capitals between opening and closing tags, unquoted attribute values and an unescaped & or < in text. The flagged line is where the parser gave up.

Is the file sent to a server?

No. The browser parses the XML in this tab. Invoices, configuration files and other private documents stay on your device.

Does XML Viewer upload my file?

No. The file is read by your browser and shown on screen without being sent anywhere. Config files with passwords, contact lists and logs remain on your own computer.

Do the online compilers run real code?

Some languages, such as Python, JavaScript, TypeScript, Lua and SQL, run inside your browser. For others, the page is mainly for reading and sharing the code, so read the note on that page to know what to expect.

Does XML Viewer cost anything or need a login?

Neither. There is no fee, no sign-up and no cap on how many files you open. It works the same on a work laptop, a home computer or a phone.

What if my file is very large?

Large logs and data files depend on your device’s memory, because the whole file is read in the browser. If a huge file feels slow, try a computer with more memory or view a smaller part of it.

Can I open a file from my phone?

Yes. Use the file picker to choose it from your phone’s storage or a downloaded attachment, and the contents appear on the page. A larger screen is easier for long files, but everything works on mobile.

Further reading

More Viewers

Other free tools for the same kind of job.

Browse all tools