Effectively an energy based life form, a Spark is the Heart and Soul of a Cybertronian. Without it, said bot would just be a mass of metal and its presence is used by Cybertronians to decide the difference between them and simple robots and drones. All Sparks are created from Primus' own life force, the Allspark, often through energy pulses from a device of the same name, or the super computer Vector Sigma. These pulses also generate Energon and Sentio Metallico, which are used to fuel and build transformers respectively.
Sparks can also be created alone, by the Matrix