It is in the dua: اللَّهُمَّ أْجُرْنِي فِي مُصِيبَتِي وَأَخْلِفْ لِي خَيْرًا مِنْهَا
اللَّهُمَّ أْجُرْنِي فِي مُصِيبَتِي وَأَخْلِفْ لِي خَيْرًا مِنْهَا
It was translated on sunnah.com as:
O Allah, reward me for my affliction and give me something better than it in exchange for it,
Imam Malik compiled it in his al-Muwatta' with a sligtly different wording:
اللَّهُمَّ أْجُرْنِي فِي مُصِيبَتِي وَأَعْقِبْنِي خَيْرًا مِنْهَا
The translation on sunnah.com is as follows:
O Allah, reward me in my misfortune and give me better than it afterwards
You may find other variations of this du'a in other hadith sources.
are synonyms -in Arabic- for the case when they are used to express a chronological order and are used the refer to something that comes after another and may take its position or replaces it. Note that this thing usually is diffeernt than the first!
The corresponding nouns in Arabic are:
Which may mean a replacement and in best case a good (pious) offspring. Or
which may mean a successor or simply the back, behind or reverse.
العَقِبُ or العُقُبُ
which both refer to the last (ending) part of something (see for example 18:44). And in the context above:
which comes with different meanings among them the last or ending (part) of everything and the replacement ...