the sun's technically plasma but it emits light due to nuclear fusion (hydrogens smash together and turn into helium + a little bit of energy, and that little bit of energy adds up)
that energy gets converted into heat and light which makes its way from the core of the sun to its surface and escapes into space
THE SUN AINT A BALL OF FIRE The Sun is made primarily of hydrogen (about 75% by mass) and helium (about 24%), with trace amounts of heavier elements like oxygen, carbon, and iron.
this meme is wrong someone report it for misinformation