Okay, that's a very dangerous situation, and I'm glad you weren't seriously injured. An exploding lead-acid battery (which is what inverter batteries almost always are) is a serious event.
Based on your description – "wrong connection," "slowly got warm," and then "exploded" – the most likely cause is Reverse Polarity Connection combined with Gas Buildup and Ignition.
Here's the breakdown of what probably happened:
-
Wrong Connection (Most Likely Reverse Polidity): You almost certainly connected the battery terminals backwards: the positive (+) terminal of the battery to the negative (-) input of the inverter/charger, and the negative (-) terminal of the battery to the positive (+) input of the inverter/charger.
-
Incorrect Current Flow & Heating:
- When connected in reverse, a very large current tries to flow in the wrong direction. Depending on the inverter's design, its internal diodes might try to block this, or its charging circuit (if active or even just connected) might essentially create a near short-circuit through the battery.
- This high current flow generates significant heat within the battery due to its internal resistance (I²R losses). This explains why the battery "slowly got warm."
-
Rapid Electrolysis and Gas Production:
- Lead-acid batteries contain water (H₂O) in their electrolyte (sulfuric acid solution). The high, incorrect current flow causes rapid electrolysis of this water.
- Electrolysis splits water into Hydrogen gas (H₂) and Oxygen gas (O₂). This mixture (oxyhydrogen) is highly explosive.
- This gas generation happens much faster than the battery's vents are designed to handle.
-
Pressure Buildup: The rapidly produced hydrogen and oxygen gases build up significant pressure inside the sealed compartments of the battery casing. The plastic casing starts to bulge under this pressure.
-
Ignition Source: All that's needed now is a spark or sufficient heat to ignite the trapped hydrogen-oxygen mixture. This ignition source could be:
- Internal Heat: The excessive heat generated by the high current flow could itself reach the ignition temperature of the gases.
- Internal Spark: Warping of the internal lead plates due to heat, or a poor internal connection within the battery, could create a small spark inside the casing.
- External Spark (Less likely if already connected): A spark created while making the connection or from a loose terminal after the incorrect connection was made, could travel through the vents. However, given it warmed up then exploded, an internal source is more likely.
-
Explosion: The ignition of the pressurized hydrogen-oxygen mixture inside the battery casing causes a violent explosion, rupturing the plastic casing and spraying battery acid and shrapnel.
In Summary: The wrong connection (reverse polarity) caused a large current to flow, generating heat and rapidly producing explosive hydrogen and oxygen gases through electrolysis. The pressure built up until the internal heat or a small spark ignited the gases, causing the battery casing to explode.
Other Less Likely Possibilities (but still related to "wrong connection"):
- Severe Short Circuit: If the "wrong connection" involved accidentally shorting the battery terminals directly with a tool or cable, this would also cause rapid heating, gassing, and potential explosion, though usually much faster than "slowly got warm."
- Connecting to AC Power: Accidentally connecting the DC battery terminals to an AC source would cause catastrophic failure very quickly, likely not described as "slowly got warm."
Safety Warning:
- Exploded batteries release corrosive sulfuric acid and potentially sharp plastic/lead fragments. Avoid touching any residue without proper protection (gloves, eye protection).
- Neutralize any spilled acid carefully (e.g., with baking soda solution).
- The inverter itself may also be damaged by the reverse polarity connection. Have it professionally inspected before attempting to use it again.
- Always double-check polarity (+ to +, - to -) before connecting any battery. Mark cables clearly if needed.