Tested with: KSA Version 2026.10.19.5638
Units in XML are written as attributes, and the attribute name is the unit. There is no separate unit field.
<MeanRadius Km="6371" />
<Mass Earths="1" />
<Inclination Degrees="28.87" />
A misspelled unit is not an error. The attribute is ignored, the value never gets read, and whatever you were setting keeps its default. Copy these exactly.
Mm, Cm, M, Km, Au, Ly
Ascending order. There is no gigameter, no decimeter and no parsec.
G, Kg, Tonnes, Mg, Gg, Tg, Pg, Eg, Zg, Yg
Plus four convenience units for astronomical bodies: Lunars, Earths, Jupiters, Suns.
Watch the spelling on those last four. It is Lunars and Suns, not Lunas and Sols. The tonne unit is written Tonnes in XML even though the field behind it is called T.
Degrees, Radians
Seconds, Minutes, Hours, Days, Weeks, Months, Years
Pa, KPa, MPa, MBar, Bar, Atm
KgPerM3, GPerM3, MgPerM3, UgPerM3, GPerCm3, TonnePerM3
Mm2, Cm2, M2, Km2
Mm3, Cm3, M3
Anything dimensionless takes Value.
<Eccentricity Value="0.0077" />
<ThermalEfficiency Value="0.75" />
Most elements accept more than one unit attribute at once and add them together. In practice nobody does this, but it means <SemiMajorAxis Km="6000" M="500"/> is 6000.5 km rather than an error.