Yes, the reasons are similar.
Work Step by Step
In the case of the sparks, the temperature characterizes the average energy per molecule. With a high temperature, but not too many molecules, the total energy is low and won't harm you. In the case of the charged metal ball, the voltage characterizes the energy per charge. With a high voltage, but not too much charge, the total energy is low and won't harm you.