Jami` at-Tirmidhi, Book 12, Hadith 24 (Tirmidhi 1172)

Abu Sa’eed Al-Khudri narrated that The Messenger of Allah said:

“It is not lawful for a woman who believers in Allah and the Last Day to travel on a trip that is three days or more, unless she is accompanied by her father, her brother, her husband, her son, or someone who is a Mahram to her.”