It is better to recite this dua in giving condolence
أَعْظَمَ اللَّهُ أَجْرَكَ، وَأَحْسَنَ عَزَاءَكَ، وَغَفَرَ لِمَيِّتِكَ
Pronunciation
A'dhamAllahu 'ajraka, wa 'ahsana 'azaa'aka wa ghafara limayyitik.
Meaning
May Allah increase your reward, grant you the tawfiq of patience (in mourning), and forgive the dead person.
Source: Al-Adhkaar lin Nawawi P. 126
Duas from IslamicAPI's Masnun Dua dataset (based on the Quran, hadith, Hisnul Muslim and Rahe Belayat). See the dataset