The Sun's gravitational force confines the positively-charged hydrogen nuclei and work with the high temperatures that cause the nuclei to move around furiously, collide at high speeds overcoming the natural electrostatic repulsion that exists between the positive charges and fuse to form the heavier helium.
What is the Sun fusing?
The Sun is a main-sequence star, and thus generates its energy by nuclear fusion of hydrogen nuclei into helium. In its core, the Sun fuses 500 million metric tons of hydrogen each second.
How did fusion start in the Sun?
The specific type of fusion that occurs inside of the Sun is known as proton-proton fusion. Inside the Sun, this process begins with protons (which is simply a lone hydrogen nucleus) and through a series of steps, these protons fuse together and are turned into helium.