180

There are plenty of "heavyweight" tools such as XmlSpy, which are good for prodding around in xml docs - but often (very often in some cases!) you just want to quickly open and browse an xml doc, and have it pretty printed. Possibly with some basic search functionality (textual is probably fine).

I usually use a browser such as IE of Firefox for this, but they tend to break down for larger file sizes (I'm often opening files in the 10s of MBs or more).

I have some ideas about how such a viewer might be implemented, so I'm sure there must be something out there that can do it, but my google-fu is letting me down.

So I thought I'd put it to the hive-mind that is SO to lead the way.

Thoughts?

tshepang
  • 12,111
  • 21
  • 91
  • 136
philsquared
  • 22,403
  • 12
  • 69
  • 98
  • 20
    @Kev I believe, that people continually voting on this thread make your arbitrary decision a bit out of synch with reality – Jeffz Feb 22 '13 at 14:20
  • 1
    @Jeffz whatever the votes, it's just a matter of time that "recommend software" questions will get out of sync. That's one of reasons why they are considered OT here. – Alois Mahdal Nov 10 '15 at 21:50
  • 1
    Note that software recommendation questions could possibly now be posted on the [software recs SE, provided it meets their requirements](https://softwarerecs.meta.stackexchange.com/questions/336/what-is-required-for-a-question-to-contain-enough-information). – jrh Apr 08 '18 at 18:43

9 Answers9

236

firstobject's 605k download lightweight native Windows free XML editor opens a 50MB file in 1.3 seconds and provides text editing, search, syntax-colored printing, plus tree view and additional XML features including formatting and full-blown CMarkup scripting built in. You can reformat an entire 50MB XML document to a different indentation (takes 3 seconds on a nothing special 2.3GHz/2GB machine).

Ben Bryant
  • 3,074
  • 1
  • 21
  • 13
  • Thanks Ben. Just came back to this question as the requirement came up again and saw your response. This tool seems to be exactlty what I was originall looking for! I haven't yet tried it on huge docs, but 5Mb docs certainly open in a fraction of a second, and pretty-pretting in about a second by just hitting the F8 key. From what you say the performance should scale well into the tens of Mbs. May have some GB docs to try it with later. That will sort the men from the boys ;-) – philsquared Aug 31 '09 at 18:19
  • 1
    I've just tried it with a 250 MB document and it works like a charm! Only thing I can't figure out is how to "make" it display HTML Entity as a value (eg, HTML Entity (decimal) from http://www.fileformat.info/info/unicode/char/160/index.htm) – Andrija Jul 13 '10 at 13:03
  • just tried this on a 103MB File and works brilliantly. Thanks for the tip. – David Steele Jun 13 '11 at 05:58
  • 5
    Tried it on a 300MB file. It opens in 4-5 seconds and shows the element tree. I can click on it to highlight the element in the text pane. Indent does not work: after ~ 10 seconds of full CPU use it says "Out of memory". Still, this is much better than most programs did on that file and I haven't yet found a better free alternative. – EMP Jun 29 '11 at 02:59
  • Awesome program. It opened a 1.2GB xml file in less than 10 seconds. No problem with search etc. Even better because you dont have to install this program but simply run it from the zip. – ToughPal Sep 29 '11 at 10:21
  • This thing rocks. I was having trouble in multiple "professional" tools with a 6MB file and this thing cut through it like butter. – whitneyland Jan 10 '12 at 16:02
  • 1
    I tried opening a 530 MB xml file on my Win 7 machine with 8 GB ram only to receive an "Out of Memory" error dialog after ~2 seconds of working. Any other editors out there that someone knows can handle huge xml files? – Kallja Jul 25 '12 at 11:05
  • Very usefull in comparison with others, but have problems aligning files greater then 500MB on my machine. Stops with out of memory error. – tomasb Oct 28 '12 at 11:25
  • I just tried this with a 1.3 GB xml and opened in about 10 seconds w/ no crashes. No other program on my WinXP comp could even open this file. Thanks for this. – Matt Feb 11 '13 at 17:28
  • It runs out of memory on 1.5GB XML file, any other solutions? – Nazariy May 13 '13 at 12:40
  • Crashed trying to open a 3GB XML file on a powerful machine. – Danny Beckett Oct 30 '13 at 04:10
  • I want to open small KB files. Can this tool show me a graphical/drop down view of an XML file ? – Steam Dec 16 '13 at 20:26
  • Just as a fwiw, using [Jotti](http://virusscan.jotti.org/en), ClamAV is reporting PUA.Spyware.XPCSpyPro in `foxesetup242.exe`. – ruffin Dec 19 '14 at 18:51
  • 2
    To open XML and text files of almost any size use [XML ValidatorBuddy](http://xml-buddy.com/large-xml-file.htm) – Clemens May 31 '17 at 14:36
  • pros: firstobject is fast and shows a simple outline view plus the actual XML in a text pane; con: lacks line numbers – buzz3791 Jun 20 '17 at 17:24
  • 1
    @Clemens - Great tip. I have just opened a 1.8Gb XML file in "XML ValidatorBuddy". – Dib Aug 03 '17 at 13:22
  • Ben, any **Mac?** – Pacerier Oct 30 '17 at 19:06
  • XML Validator Buddy indeed opened by 1.3 GB file properly but I'm missing functionality to expand/collapse the tree which makes browsing the file clumsy... – Gerben Feb 12 '19 at 12:21
  • can't give enough upvote, I have been using VS Code, Notepad++, and they all seem to hang poorly for more than 5 minutes and crash in most cases with files of 50mb - 100mb. I used this tool, the best part is that it also generates a schema for the XML elements, so it makes it easier to write the parsers in other languages like C#. Amazing software, thanks for sharing. – Afzaal Ahmad Zeeshan Apr 24 '20 at 13:04
  • I tested search in a XML 52MB size and its works so good – LuisEduardox May 11 '21 at 04:08
  • Excellent, added in my blog post: https://developingdaily.com/article/windows/best-xml-viewer/264 Thanks – Vikas Lalwani Aug 26 '22 at 06:05
12

XML Copy Editor is perfect for this type of thing.

yalestar
  • 9,334
  • 6
  • 39
  • 52
  • 1
    I just tried this. Very similar to EditPlus (see comments to IKurts). From trying a few times (not rigourous profiling), it seems slightly faster than EditPlus (both it's own startup time, and the load time for the 30MB doc) - but still parses the whole doc before showing. – philsquared Nov 24 '08 at 10:18
  • Hey, **Mac OS X?** – Pacerier Oct 30 '17 at 19:08
  • It crashed while loading a 1.3 GB XML file (version 1.2.1.3 x64) – Gerben Feb 12 '19 at 11:49
5

I like the viewer of Total Commander because it only loads the text you actually see and so is very fast. Of course, it is just a text/hex viewer, so it won't format your XML, but you can use a basic text search.

schnaader
  • 49,103
  • 10
  • 104
  • 136
  • 2
    Sometimes speed is the only thing that matters, and in such cases Total Commander's Lister is indeed the best. I have used it to quickly find something in files over 500MB. Some goes for the FAR Manager's built-in viewer. – ccpizza Feb 09 '11 at 13:04
4

Try EditPlus - http://www.editplus.com/

lkurts
  • 388
  • 2
  • 6
  • 2
    Thanks Ikurts. I gave it a try and it certainly does a better job than the browers. It can handle large files fairly well (I tried it with some 30MB XML docs), and didn't crash! However, it does appear to be parsing the whole doc before showing it, which is not what I wanted. Voting you up anyway – philsquared Nov 24 '08 at 10:03
  • For MacOS, use Xmplify. If your file is one long line, just push the Format button and save the file. – Samuel De Backer Nov 30 '17 at 13:11
  • EditPlus shows an empty file when I try to load a 1.3 GB XML file. – Gerben Feb 12 '19 at 11:56
4

I have tried dozens of XML editors hoping to find one which would be able to do some kind of visualization. The best lightweight viewer for windows I have found was XMLMarker - too bad the project has been dead for some years now. It is not so useful as an editor, but it does a good job of displaying flat XML data as tables.

There are tons of free editors that do XML syntax highlighting, including vim, emacs, scite, eclipse (J2EE edition), jedit, notepad++.

For heavyweight XML features, like XPath support, XSLT editing and debugging, SOAP/WSDL there are some good commercial tools like, XMLSpy, Oxygen, StylusStudio.

JEdit is open-source and also has plugins for XML, XPath and XSLT.

Word-2003 is fairly good for visualizing (but don't use it for editing). Excel-2003 and up also does a good job at visualizing flat XML data and can apply XSL transformations (again, no good as an editor).

ccpizza
  • 28,968
  • 18
  • 162
  • 169
3

JEdit and its XML-plugin.

shezi
  • 560
  • 3
  • 18
  • Thanks. I was ideally looking for a dedicated xml viewer, but if JEdit does the job I won't rule it out. I shall take a look. Not tried it for a few years, but last time I did (as a text editor) I don't remember being bowled over... – philsquared Nov 21 '08 at 13:37
  • Ok, I tried it. I have to say I really hate vanilla Java GUIs, and JEdit is Java GUI to the core. That said it does seem to do it's parsing on a background thread, and shows what it can as soon as it has it. So it starts showing my 30MB file within 2-3 seconds.... [continued] – philsquared Nov 24 '08 at 10:28
  • ... You can't then jump to later parts of the doc until they have been parsed, of course - and I think it does still do a full in memory parse - so it might struggle more with even larger docs, but in terms of my requirements this is the best so far. Thanks – philsquared Nov 24 '08 at 10:29
2

http://www.firstobject.com/dn_editor.htm is so far the best and lightest editor available with handful of utilities. I recommend using it - tried with up to 400 MB of files and more than a million records :)

doubleDown
  • 8,048
  • 1
  • 32
  • 48
utkarshk
  • 147
  • 7
  • 4
    That's the same thing @Ben Bryant mentions in the accepted answer from three years earlier. ;) – ruffin Oct 02 '12 at 15:12
0

TextPad has a free xmltidy plugin that pretty-prints your XML. Nice and fast, although TextPad is shareware.

skaffman
  • 398,947
  • 96
  • 818
  • 769
0

I like Microsoft's XML Notepad 2007, but I don't know how it handles very large files, sorry.

user39603
  • 2,235
  • 1
  • 16
  • 13