# xml2json (Dart)

> Convert XML to JSON in Dart with the Parker, Badgerfish, GData or OpenRally conventions

Source: https://talira.ai/catalog/xml2json-dart-3ap67sg0
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library
- Categories: [libraries / xml](https://talira.ai/categories/libraries/xml), [languages / dart](https://talira.ai/categories/languages/dart)
- Licence: MIT[^1]
- Pricing: Free and open source[^1]
- Pricing notes: Free and open source (MIT).
- Free tier: yes[^1]
- Backed by: [Steve Hamblett](https://talira.ai/orgs/steve-hamblett.md)

xml2json is a Dart and Flutter package that parses XML strings, using the [xml](https://talira.ai/catalog/xml-dart-nwpm2xnc.md) package, and turns the parse tree into JSON following one of four conventions: Parker, a lean but lossy form for simple collections (optionally with attributes), Badgerfish and Google Data (GData), which keep attributes and namespaces for feeds such as Atom, and OpenRally. Its README documents the exact rules each converter follows.

## Links

- GitHub: https://github.com/shamblett/xml2json

## Problems it solves

- turn an XML API response into JSON in a Flutter app
- convert an Atom feed to JSON in Dart while keeping attributes and namespaces
- parse simple XML records into JSON maps in Dart

## Features

- Parker conversion, optionally with attributes
- Badgerfish conversion
- Google Data (GData) conversion
- OpenRally conversion
- parses with the xml package

## Trust

Overall: 0.33 out of 1.
Signals: maintenance 0.45, adoption 0.35, momentum 0.04, community 0.50, backing 0.30, extensibility 0.00.

- last commit 3 months ago
- 56 GitHub stars
- 17 contributors
- backed by Steve Hamblett

## Sources

[^1]: https://github.com/shamblett/xml2json/blob/master/LICENSE (checked 29 Nov 2026)
