Tools for converting between various data formats
Updates
Recently shipped improvements
Automatically convert XML data structures to TypeScript interfaces or types.
Supports various XML formats like config files, RSS feeds, SVG, Android Manifest.
Automatic XML structure parsing
XML attribute handling (@_prefix)
Automatic nested element separation
Repeated elements to array conversion
Set a meaningful root interface name
XML attributes are converted with @_ prefix
Repeated elements are automatically treated as arrays
A tool that automatically generates TypeScript interfaces or types by analyzing XML data structures. Supports various XML formats including RSS feeds, SVG, Android Manifest, and configuration files, with accurate mapping of XML elements and attributes to types.
Enter XML
Enter XML in the left editor or load a sample such as RSS, SVG, or Android Manifest.
Set the Options
Set the root interface name, output format (interface/type), export, readonly, and null-handling options.
Review and Copy the Result
Review the converted TypeScript code in the right editor, then copy it or download a .ts file.
XML attributes become properties with an @_ prefix. For example, the id attribute in <item id='1'> becomes '@_id: string.' This distinguishes attributes from element content.
Repeated elements with the same name under one parent are automatically treated as an array. For example, multiple <item> elements become item: Item[].
The parser handles XML namespaces and generates types that include namespace prefixes. Review the generated types when working with a complex namespace structure.
Yes. An SVG sample is included. Because SVG is XML-based, its elements and attributes can be converted accurately into TypeScript types.
The contents of a CDATA section are treated as text and converted to string. The XML parser resolves CDATA automatically.