When the gas in the nebula starts to come together it will get hot enough for nuclear fusion to start.
Hydrogen fuses to form Helium, releasing A LOT of energy.
The star is relatively stable, as the gravitational forces are balanced with the pressure being formed by nuclear fusion.
Eventually it will run out of Hydrogen to fuse, and begin to fuse Helium, causing the star to expand and cool, becoming a Red giant star.