Praise be to Allah.
If you prayed without wudu by mistake, you have to do wudu and repeat your prayer. The scholars are unanimously agreed on that, because purity (taharah) is one of the conditions of prayer being valid. The Prophet (peace and blessings of Allah be upon him) said: “Allah does not accept the prayer of any of you if he breaks his wudu, unless he does wudu again.” (Narrated by al-Bukhari, 6954; Muslim, 225)
Muslim (224) narrated that ‘Abd-Allah ibn ‘Umar said: I heard the Messenger of Allah (peace and blessings of Allah be upon him) say: “No prayer is accepted without purification .”
Al-Nawawi (may Allah have mercy on him) said in al-Majmu’, 2/79:
“The Muslims are unanimously agreed that it is haram for a person who has broken his wudu to pray, and they are unanimously agreed that his prayer is not valid, whether he is aware that he broke his wudu or is unaware of that or forgot . But if he prayed because he was unaware of it or forgot, then there is no sin on him, but if he was aware that he had broken his wudu and that it was haram for him to pray in this situation, then he has committed a grave sin.
And Allah knows best.