Automatic, spontaneous are not close synonyms but they agree in meaning brought into being or action by an internal as opposed to an external agency.
Automatic was originally used to describe a thing that was self-acting or self-activated because it contained the principle of motion within itself.
Now it is applied more often to machines and mechanical contrivances which, after certain conditions have been fulfilled, continue to operate indefinitely without human supervision or until the conditions have materially changed; thus, an automatic firearm is so constructed that after the first round is exploded the force of the recoil or gas pressure loads and fires round after round until the ammunition is exhausted or the trigger is released; a thermostat is an automatic device which maintains the temperature of artificially heated rooms by operating the appropriate parts of a furnace when the temperature exceeds or falls below the point at which it is set.
Spontaneous (see also SPONTANEOUS) applies not so much to objective things as to processes, particularly natural processes, thought of as originating without external agency or without human agency; thus, spontaneous generation implies origin of living directly from nonliving matter; spontaneous combustion implies a generation of heat through chemical changes in matter causing it to burn; a spontaneous growth refers to vegetation produced neither from humanly sown seed nor from plantings.