Sunan Ibn Majah, Volume 2, Book 5, Hadith 1308 (DarusSalam)

It was narrated that Umm ‘Atiyyah said: “The Messenger of Allah said: ‘Bring out the women who have attained puberty and those who are in seclusion so that they may attend the ‘Eid prayer and (join in) the supplication of the Muslims. But let the women who are menstruating avoid the prayer place.”

حَدَّثَنَا مُحَمَّدُ بْنُ الصَّبَّاحِ، أَنْبَأَنَا سُفْيَانُ، عَنْ أَيُّوبَ، عَنِ ابْنِ سِيرِينَ، عَنْ أُمِّ عَطِيَّةَ، قَالَتْ قَالَ رَسُولُ اللَّهِ ـ صلى الله عليه وسلم ـ ‏ "‏ أَخْرِجُوا الْعَوَاتِقَ وَذَوَاتِ الْخُدُورِ لِيَشْهَدْنَ الْعِيدَ وَدَعْوَةَ الْمُسْلِمِينَ ‏.‏ وَلِيَجْتَنِبَنَّ الْحُيَّضُ مُصَلَّى النَّاسِ ‏" ‏ ‏.‏

sunnah.com