The hyperfine interaction of an electron with the unpolarized nuclei in thermally annealed self-assembled InAs/GaAs quantum dots (QDs) is theoretically analyzed. For this purpose, the thermal annealing process of the quantum dots is numerically modeled to obtain the nuclear composition as well as the electron ground state in the QDs. To check the reliability of calculations, the ground-state excitonic transition energies are compared with photoluminescence data from a set of annealed dots. From these results, the electron localization volume and the partial contributions of the In, Ga, and As nuclei to the hyperfine interaction are calculated as functions of annealing temperature. The contribution of the indium nuclei to the hyperfine interaction dominates up to high temperatures of the annealing (Ta =980°C), for which the In content in the dots does not exceed 25%. Simulations of the effect of the nuclear-spin fluctuations on the electron-spin polarization decay are in good agreement with the experiment.