When the Prophet ﷺ came to Medina, he found the Jews observing fast on the day of 'Ashurah; so they were asked about it (by the Prophet). They said: This is a day on which Allah gave Moses domination over Pharaoh. We fast on it out of reverence to him. The Messenger of Allah ﷺ said: We have a closer connection with Moses than you have. He then gave orders that it should be observed.
لَمَّا قَدِمَ النَّبِيُّ ﷺ الْمَدِينَةَ وَجَدَ الْيَهُودَ يَصُومُونَ عَاشُورَاءَ فَسُئِلُوا عَنْ ذَلِكَ فَقَالُوا هَذَا الْيَوْمُ الَّذِي أَظْهَرَ اللَّهُ فِيهِ مُوسَى عَلَى فِرْعَوْنَ وَنَحْنُ نَصُومُهُ تَعْظِيمًا لَهُ فَقَالَ رَسُولُ اللَّهِ ﷺ نَحْنُ أَوْلَى بِمُوسَى مِنْكُمْ وَأَمَرَ بِصِيَامِهِ