Sure Al-Maaida

5:27

۞ وَٱتْلُ عَلَيْهِمْ نَبَأَ ٱبْنَىْ ءَادَمَ بِٱلْحَقِّ إِذْ قَرَّبَا قُرْبَانًۭا فَتُقُبِّلَ مِنْ أَحَدِهِمَا وَلَمْ يُتَقَبَّلْ مِنَ ٱلْءَاخَرِ قَالَ لَأَقْتُلَنَّكَ ۖ قَالَ إِنَّمَا يَتَقَبَّلُ ٱللَّهُ مِنَ ٱلْمُتَّقِينَ

Und verlies ihnen die Kunde von den beiden Söhnen Adams, der Wahrheit entsprechend, als sie ein Opfer darbrachten. Da wurde es von dem einen von ihnen angenommen, während es vom anderen nicht angenommen wurde. Der sagte: "Ich werde dich ganz gewiß töten." Der andere sagte: "Allah nimmt nur von den Gottesfürchtigen an.

Tafsir 5:27

Relate with the truth O Messenger, to these Jews who are jealous and who do wrong, the incident of the two sons of Adam, Cain and Abel, When they both offered a sacrifice to gain closeness to Allah, Allah accepted the sacrifice offered by Abel because he was mindful of Him and did not accept the offering of Cain because he was not mindful of Allah. Cain was unhappy about the fact that Abel’s sacrifice was accepted and jealously said, ‘I will kill you, O Abel!’ Abel replied, ‘Allah only accepts the offering of the one who is mindful of Him by fulfilling His instructions and avoiding His prohibitions’.