Free XML Parser/Generator Libraries
Free XML Parser/Writer Source Code
Free XML Parser/Generator Libraries
The free and/or open source XML parser libraries listed here let you read, parse and write XML documents from your programs/applications. They are not only useful for dealing with the various XML-based formats around, but they can also be handy if you want to create configuration or data files for your programs. This speeds up development since you do not have to invent a new format and write and debug code to handle it.
Note that the libraries listed vary in their approach. Some only handle the very basic XML format, but are relatively fast XML parsers that are easy to understand and use (since they do the bare minimum). Others are more full-fledged, handling the numerous XML standards from W3C and others. Which you choose will of course depend on your purpose and requirements.
Related Pages
- How to Make / Create Your Own Website: The Beginner's A-Z Guide
- Free Game Engines (Game Programming Libraries)
- Free Database Libraries and Source Code
- Free Compression and Archiving Libraries and Source Code
- Free C/C++ Compilers and Interpreters
- How to Register Your Own Domain Name
- Does the Price of a Domain Depend on the Name Chosen? Why do Some Domains Cost So Much?
- Free HTML Editors and WYSIWYG Web Editors
Free XML Parser/Generator Libraries
- Mini-XML (C)
Mini-XML is a C library that lets you read and write XML files. It can handle reading of UTF-8 and UTF-16 files and write UTF-8 files; supports integer, real, text and opaque (CDATA) data types in leaf nodes; has functions for creating, finding and walking the tree; etc. It does not validate the source. It is licensed under the Apache licence version 2.0.
- ezXML (C)
EzXML is a C library for parsing XML files. It loads the entire XML file into memory at once, although it also has a function that lets you load it using
mmap()
(thus allowing the operating system to page in the data as needed). It is not a validating parser, and will either ignore or halt processing files if they are not well-formed (although it is not necessarily able to detect every possible well-formedness error). It is released under the MIT license.- XMLIO (C++)
XMLIO is a high-level C++ library with base classes and functions for reading and writing XML files. It is licensed under the GNU LGPL. (Note that this XMLIO is different from the other project of the same name listed below.)
- sxmlc (C)
Sxmlc, which probably stands for Simple XML parser written in C, implements a subset of the XML specifications. The intent of the library is to "give C developers an API for XML handling as simple and flexible as possible". It does not validate the XML it is parsing. It is released under the BSD 2-clause licence.
- Libxml2 (C)
Libxml2 is a C XML parser library, with an assortment of bindings/wrappers for other languages if you don't use C (eg, C++, Perl, Delphi/Pascal, Ruby, PHP, Java, Rexx, AppleScript, etc). It implements the XML standard, namespaces, XML Base, XML Inclusions (XInclude) 1.0, XML Catalogs Working Draft, Canonical XML Version 1.0, W3C XML Schemas Part 2, etc. It has partial support for DOM and SAX (minimal). It is released under the MIT License.
- RapidXML (C++)
RapidXML is a minimal DOM-style XML parser designed for speed. The entire library is contained in a single header file, so no building or linking is needed. It parses the XML into C++ data structures with no validation or decoding whatsoever; strings, in the same encoding as the source file, are returned for everything. Note that this parser is not a W3C-compliant parser. It is released under the Boost Software License or the MIT License, at your option.
- Expat (C)
Expat is a stream-oriented C parser library for XML documents. To use it, your application creates a new parser object, registers callback functions (or handlers) to process the various elements found in the XML document (eg, start and end tags), then call the parser with a buffer pointing to a piece of the document at a time (allowing you to parse huge documents that don't fit into memeory). The library can handle UTF-8 and UTF-16 characters, namespaces and DTDs. This is open source software, with a license that "is the same as the MIT/X Consortium license" (from their README).
- Apache Xerces (C++, Java, Perl)
Apache Xerces is a validating XML parser and parser library that lets your program read and write XML documents. The C++ version of the library conforms to the W3C XML 1.0 (3rd edition) and 1.1 specifications (except normalization checking in 1.1); DOM Level 1; DOM Level 2 Core, Traversal and Range; DOM Level 3 Core, Load and Save; SAX 1.0 and 2.0; the W3C namespaces in XML 1.0 and 1.1; XML Schema parts 1 and 2; XML inclusions (XInclude) 1.0 second edition; and Element Traversal Specification. The Perl version, XML::Xerces, is implemented using the C++ library. The Java library supports XML 1.0 (4th edition) and 1.1 (2nd edition); namespaces in XML 1.0 (2nd edition) and 1.1 (2nd edition); XML Schema 1.0 (2nd edition) and 1.1; XML Schema Definition Language (XSD): Component Designators; XInclude 1.0 2nd edition; OASIS XML Catalogs 1.1; SAX 2.02; DOM level 2 Core, Events, Traversal and Range; DOM Level 3 Core, Load and Save; JAXP 1.4; StAX 1.0 Event API; and Element Traversal. Xerces is released under the Apache Software License.
- Pugixml (C++)
Pugixml is a light-weight C++ non-validating XML processing library with XPath 1.0 and Unicode support. The library parses your data and stores it in memory as a tree, which can be accessed via API or XPath expressions. The tree can also be modified and saved to a file. Pugixml is released under the MIT License.
- TinyXML (C++)
TinyXML is a minimal DOM-style XML parser that creates C++ objects from your XML data that can be read, modified and saved. There is no validation, handling of DTDs or much of anything else, as such it has a small footprint. It is released under the Zlib licence.
- XMLIO (C, C++)
[Update: this library is no longer available.] Paul Miller's XMLIO is a minimal streaming XML parser for C and C++ programs. You set handlers to process the various elements as and when they are encountered. The parser does not handle validation, DOMs, namespaces, etc. It is released under the GNU Library General Public License. Note that there is another project of the same name by different developers (also listed on this page).
Related Pages
- Free Installers and Setup Utilities
- Free Source Code Version Control Software
- Free Encryption / Cryptographic Libraries and Source Code
- Free Autorun/Autoplay DVD and CD Menu Creation Software
- Free Hard Disk Backup and Restore, Hard Disk Image and Cloning Utilities
- Should You Get a Domain Name with Spaces or Dots In Between to Improve Readability?
- What's the Difference Between a Domain Name Registrar and a Web Host?
- Does the Price of a Domain Depend on the Name Chosen? Why do Some Domains Cost So Much?
Newest Pages
- How to Convert Your Website from XHTML 1.0 to HTML5 the Quick and Easy Way
- How to Set the Height of a DIV Relative to a Browser Window (CSS)
- Free EPUB Readers (Ebook Viewing Software)
- How to Generate the Free Let's Encrypt SSL Certificate on Your Own (Windows) Computer
- How to Insert Meta Tags into a Web Page with BlueGriffon
- How to Play a Song (or Some Other Audio Clip) from a List on a Website
- Two Ways to View a Binary File on Windows Without Installing Anything
- How to Draw a Horizontal Line on a Web Page with Expression Web
- How to Create a Website Free of Charge
- Why Can't I Make Up Any Domain I Want? Is There a Way to Do Away with a Registrar Altogether?
How to Link to This Page
It will appear on your page as:
Free XML Parser/Generator Libraries