A dynamite gun is any of a class of artillery pieces that use compressed air to propel an explosive projectile (such as one containing dynamite). Dynamite guns were in use for a brief period from the 1880s to the beginning of the twentieth century.
Because of the instability of early high explosives, it was impractical to fire an explosive-filled shell from a conventional explosive-fired gun. The violent deflagration of the propellant charge and the sudden acceleration of the shell would set off the explosive in the barrel of the weapon. By using compressed air, the dynamite gun was able to accelerate the projectile more gradually through the length of the barrel.
Guns for naval use were supplied with air from shipboard compressors. A small model for field use by land forces employed a powder charge to drive a piston down a cylinder, compressing air that was then fed into the gun barrel. This field model was famously used by Theodore Roosevelt's Rough Riders during the Spanish–American War, but had actually been used previously by Cuban insurgents against Spanish forces.
The guns fired a relatively lightweight shell; necessarily the guns had a low muzzle velocity, requiring a high angle of fire even at short ranges. This increased the flight time of the shell, resulting in a loss of accuracy.
By 1900, the availability of stable high explosives, the longer range of conventional artillery, the gun's mechanical complexity, and its inherent limitations made the dynamite gun obsolete.