developer

XML / HTML Formatter

Format messy XML or HTML with proper indentation and structure. Validates syntax and highlights errors with line numbers. Minify for production. Saves recent pastes.

Output appears here
History saved locally

Format XML and HTML online

This formatter uses the browser's native DOMParser for XML validation — the same engine your browser uses. For HTML it applies smart indentation handling void elements (br, img, input etc.) correctly without adding extra depth.