The electricity produced when two balloons are rubbed and then stick together is static electricity, commonly shortened to static. Rubbing transfers electrons between materials through the triboelectric effect, leaving the balloons with an imbalance of electric charge.
Rubber tends to gain electrons during contact with materials such as hair, wool or clothing. If both balloons acquire the same type of charge, they normally repel one another; a rubbed balloon can also attract a neutral wall because its electric field shifts charges in the wall slightly. The exact result depends on the balloon material, the fabric, humidity and how the balloons are rubbed.
Static electricity is different from the continuous current flowing through a wire. The charge remains largely in place on an insulating balloon until it leaks away or suddenly discharges, sometimes producing a tiny spark. Dry air makes the effect more noticeable because moisture helps charges dissipate.