In this work, we compute the rates and numbers of different types of stars and phenomena (supernovae, novae, white dwarfs, merging neutron stars, black holes) that contributed to the chemical composition of the Solar System. During the Big Bang, only light elements formed, while all the heavy ones, from carbon to uranium and beyond, have since been created inside stars. Stars die and release the newly formed elements into the interstellar gas. This process is called ‘chemical evolution’. In particular, we analyse the death rates of stars of all masses, whether they die quiescently or explosively. These rates and total star numbers are computed in the context of a revised version of the two-infall model for the chemical evolution of the Milky Way, which reproduces the observed abundance patterns of several chemical species, the global solar metallicity, and the current gas, stellar, and total surface mass densities relatively well. We also compute the total number of stars ever born and still alive as well as the number of stars born up to the formation of the Solar System with mass and metallicity like those of the Sun. This latter number accounts for all the possible existing Solar systems that can host life in the solar vicinity. We conclude that, among all the stars (from 0.8 to 100 M⊙) that were born and died from the Big Bang up until the Solar System formation epoch and that contributed to its chemical composition, 93.00% were stars that died as single white dwarfs (without interacting significantly with a companion star) and originated in the mass range of 0.8–8 M⊙, while 5.24% were neutron stars and 0.73% were black holes, both originating from core-collapse supernovae (M > 8 M⊙); 0.64% were Type Ia supernovae and 0.40% were nova systems, both originating from the same mass range as the white dwarfs. The number of stars similar to the Sun born from the Big Bang up until the formation of the Solar System, with metallicity in the range 12+log(Fe/H)= 7.50 ± 0.04 dex, is ~31•107, and in particular our Sun is the ~2.61• 107-th star of this kind.