That’s a very interesting question, and one that can often be very difficult to answer when getting deep into the details, but I’ll try and do a quick “back-of-the-envelope” calculation for you and mention when these tricky little details might become important and change my answer.
Here is the basic problem to solve. The Sun is emitting energy at a somewhat constant rate. We call this its Luminosity. A quick internet search gives our Sun’s luminosity from radiation to be about 3.846 × 1026 Watts. That is a huge number, meaning there must be a very powerful energy source within the Sun, and in all stars for that matter. As you may know, scientists in the early and mid 20th century gradually began to understand the mechanism behind this energy source, namely nuclear fusion, when two lighter atoms combine to create a heavier atom, releasing huge amounts of energy in the process. This process takes place in the core, or central regions, of a star where temperature and pressure are high enough for fusion to occur.
There are several types of nuclear reactions that can take place inside a star, but in our Sun the dominant mechanism is called the Proton-Proton Chain (abbreviated as P-P Chain) reaction. However, even the P-P Chain has several different types, or pathways! Ignoring the details of these reactions, let’s just say that throughout the P-P Chain, 4 protons combine to create the nucleus of a Helium atom.
If you do the math, there is a peculiar difference in the mass of the reactants (4 Protons) and the product (1 Helium nucleus). Four protons have a mass of m4p = 6.690 × 10-27 kg while 1 Helium nucleus has a mass of mHe = 6.644 × 10-27 kg. The difference in mass between the two is Δm = 4.624 × 10-29 kg. This missing mass is exactly what gets converted into energy during the fusion process! Einstein’s most famous equation, E = Δm c2, states that mass and energy are equivalent and interchangeable. So if we plug this mass difference into Einstein’s equation, we get an energy of E = 4.162 × 10-12 Joules. This is the amount of energy released per fusion reaction. To match the production of energy inside the Sun with the release of energy at the Sun’s surface, we can simply divide the Luminosity from before with the energy released per reaction to get the number of reactions necessary, per unit time. In this case, since I quoted the Sun’s luminosity in Watts, which is Joules per Second, the nuclear reaction rate we calculate will be in reactions per second.
This value comes out to be 9.242 × 1037 reactions/second. If this is the reaction rate, and each reaction uses up the difference in mass calculated above, then multiplying the two will give us the rate of mass loss, in units of kilograms per second. This comes out to be 4.27 × 109 kg/second. This seems like a huge number, and it certainly is relative to our standards here on Earth, but relative to the total mass of the Sun, Msun = 2 × 1030 kg, it is but a tiny fraction.
But finally we can estimate just how much mass the Sun has used up throughout its lifetime. Another internet search gives the age of our Sun to be about 4.6 billion years! Multiplying this timescale by our mass loss rate (NOTE: I converted the mass loss rate to units of kilograms per year beforehand), we get a total mass loss value of:
Here is another website calculating the same thing, although with a slight twist at the end, if you’d like to check my answers, and here is some information on neutrinos, another complication to this calculation. Neutrinos are tiny, mysterious particles which rarely interact with other particles, making them very difficult to detect. They are a by-product of nuclear fusion and carry “invisible energy” away from the Sun. I find them fascinating and very fun to read about.
Hope this was helpful, and sorry for the long answer!