Logo
Home Products Support Contact About Us
arrow1 File Converters
arrow1 TIFF and PDF apps
arrow1 Forensic
arrow1 Freeware

Convert XML Files Via Command Line With Total XML Converter

Total XML Converter converts XML to JSON, CSV, XLSX, XLS, PDF, HTML, DOC, RTF, TXT, TIFF, JPEG, PNG, SQL, DBF, Access — both via GUI and command line. It handles complex nested XML, supports XSLT transformation, and processes entire folders in batch. Buy a personal license for as low as $59.90.

For server-side use without a GUI, see Total XML Converter X — the ActiveX/COM server edition with the same command-line interface.

Usage of the command line prompt is as follows:

XMLConverterX.exe  "<source>"  "<destination>"  <options>

Be sure to use quotation marks for any paths with spaces.

Note you can use macros in the destination path:
  •  <DATE[:format]> - current date, default format is yyyymmdd
  •  <TIME[:format]> - current time, default format is hhmmss

For example: destination "C:\<DATE>_<TIME:hhmm>" produces file C:\20200605_0436

Options:

  • -log - <Log file name> Don`t show errors. Write them to the log file
  • -verbosity - Log file verbosity
    • error - Write to log file only errors (default)
    • detail - Write detailed log file
  • -logmode - Log file mode
    • overwrite - Overwrite (default)
    • append - Append
  • -xmllog - XML format log file name
  • -list - File with file masks to convert. Simple text file, each path on new line
  • -Recurse:off - Include subfolders
  • -do - Delete originals after conversion
  • -kfs - Keep folder structure in output
  • -kfl:off - Keep folder level
  • -fo - Force overwrite existing files
  • -rename:off - Force rename existing files instead of overwriting
  • -threads - Multi-thread processing (0 = auto)
  • -limit - Limit converted files to count
  • -ds:off - Copy original date stamps to converted documents
  • -sort - Sort source file list
    • unsorted - Unsorted, natural order (default)
    • name - Sort by file name
    • date - Sort by file modification date
    • numbers - Sort by numbers in file name
  • -ext - Use custom extension for output files
  • -optionfile - Text file with options to use, "opt=value", one line per option
  • -msuccess - Move successfully converted files to this folder
  • -merror - Move problem files to this folder
  • -IgnoreInvalidSource:off - Skip files that cannot be read instead of aborting the batch
  • -c - Convert to
    • JSON - convert to JSON
    • CSV - convert to CSV
    • Excel - convert to XLSX
    • XLS - convert to XLS
    • PDF - convert to PDF
    • HTML - convert to HTML
    • DOC - convert to DOC
    • RTF - convert to RTF
    • TXT - convert to TXT
    • TIFF - convert to TIFF
    • JPEG - convert to JPEG
    • PNG - convert to PNG
    • SQL - convert to SQL
    • DBF - convert to DBF
    • Access - convert to Access MDB
  • -xslt - Path to XSLT stylesheet. Applied to every source file before conversion — no two-step pipeline needed
  • -method - Rendering method for structured output
    • table - Expand repeated XML elements into rows (default)
    • highlight - Render XML tree with syntax colouring for human review
    • report - Generate tabular report from a tables definition file
  • -tables - Path to tables definition file (used with -method report)
  • -detectcell:off - Auto-detect numeric, date, and text cell types when writing to spreadsheet output
  • -plain:off - Flatten nested XML elements into one wide table
  • -separator - CSV field separator character
  • -comma - CSV quote character (use #ASCII code, e.g. #39 for apostrophe)
  • -combine:off - Combine all converted files into one document (PDF, TIFF)
  • -template - Output filename template
  • -pc - PDF file compression
    • F - Fastest compression
    • N - Normal compression
    • M - Maximum compression
  • -mp - PDF master (owner) password
  • -up - PDF user password
  • -perm - PDF user permissions
    • Print - Print
    • Copy - Copy
    • Modify - Modify
    • Annotation - Annotation
    • FormFill - FormFill
    • Accessibility - Accessibility
    • DocAssembly - DocAssembly
    • HighResPrint - HighResPrint
  • -pdfa:off - PDF/A compatibility mode
  • -pdfver - PDF document format version 1.2 – 1.6
  • -TM - Top Margin (inches)
  • -LM - Left Margin (inches)
  • -BM - Bottom Margin (inches)
  • -RM - Right Margin (inches)
  • -po - Paper Orientation
    • Portrait - Portrait
    • Landscape - Landscape
  • -ps - Paper size
    • A3 - A3
    • A4 - A4
    • A5 - A5
    • B5 - B5
    • Letter - Letter
    • Legal - Legal

Examples:

  • XMLConverterX.exe "C:\inbox\invoice.xml" "C:\out\invoice.pdf" -cPDF
    Convert a single XML file to PDF
  • XMLConverterX.exe "C:\inbox\*.xml" "C:\out\" -cJSON
    Convert all XML files in a folder to JSON
  • XMLConverterX.exe "C:\reports\*.xml" "C:\out\" -cExcel -detectcell -plain
    Convert XML to Excel with auto-detected cell types and flattened nested elements
  • XMLConverterX.exe "C:\inbox\*.xml" "C:\out\" -cCSV -separator ";" -comma "\""
    Convert XML to CSV with semicolon delimiter and double-quote character
  • XMLConverterX.exe "C:\inbox\*.xml" "C:\out\" -cPDF -xslt "C:\xsl\invoice.xsl"
    Apply an XSLT stylesheet to every XML before converting to PDF
  • XMLConverterX.exe "C:\inbox\config.xml" "C:\out\config.pdf" -cPDF -method highlight
    Render the XML tree with syntax colouring for human review
  • XMLConverterX.exe "C:\inbox\orders.xml" "C:\out\orders.xlsx" -cExcel -method report -tables "C:\schemas\orders.tbl"
    Generate a tabular report using a tables definition file
  • XMLConverterX.exe "C:\datalake\*.xml" "C:\out\" -cJSON -Recurse -kfs
    Recurse all subfolders and mirror the folder structure in the output
  • XMLConverterX.exe "C:\reports\*.xml" "C:\out\daily-report.pdf" -cPDF -combine -sort name
    Combine many XML files into one PDF report in alphabetical order
  • XMLConverterX.exe "C:\inbox\*.xml" "C:\out\" -cJSON -msuccess "C:\done" -merror "C:\quarantine" -IgnoreInvalidSource -threads 0
    Server queue: route good files to done folder, bad files to quarantine, process in parallel
  • XMLConverterX.exe -list "C:\queues\nightly.txt" "C:\out\<DATE>\" -cPDF -log "C:\logs\xml.log" -verbosity detail -logmode append
    Process a list file, write each run to a date-stamped output folder, and append to a detailed log

Contact Coolutils Team


Email (old-fashioned but still preferred)
To make sure we get your email, use our contact form.


+1 (855) 418-2323 (USA/Canada Toll Free)
When you leave a voicemail remember to tell us your email address. We need it to locate your order.


Latest News

Newsletter Subscribe

No worries, we don't spam.


© 2026. All rights reserved. CoolUtils File Converters

Cards