It is the day on which Allah granted victory to Moses and (his people) Bani Isra'il over the Pharaoh and we observe fast out of gratitude to Him. Upon this the Messenger of Allah ﷺ said: We have a closer connection with Moses than you have, and he commanded to observe fast on this day.
قَدِمَ رَسُولُ اللَّهِ ﷺ الْمَدِينَةَ فَوَجَدَ الْيَهُودَ يَصُومُونَ يَوْمَ عَاشُورَاءَ فَسُئِلُوا عَنْ ذَلِكَ فَقَالُوا هَذَا الْيَوْمُ الَّذِي أَظْهَرَ اللَّهُ فِيهِ مُوسَى وَبَنِي إِسْرَائِيلَ عَلَى فِرْعَوْنَ فَنَحْنُ نَصُومُهُ تَعْظِيمًا لَهُ فَقَالَ النَّبِيُّ ﷺ نَحْنُ أَوْلَى بِمُوسَى مِنْكُمْ فَأَمَرَ بِصَوْمِهِ