I heard the Messenger of Allah ﷺ say, "When your wives ask your permission to go to the mosques, grant them permission."
حدثنا ابن نمير حدثنا حنظلة سمعت سالما يقول سمعت
سمعت رسول الله ﷺ يقول إذا استأذنكم نساؤكم إلى المساجد فأذنوا لهن
Its isnad is sahih, and it is an abridgment of 6296.