وَعَنْ أَنَسٍ رَضِيَ اَللَّهُ عَنْهُ
قَالَ: «كَانَ رَسُولُ اَللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: إِذَا خَرَجَ مَسِيرَةَ ثَلَاثَةِ أَمْيَالٍ أَوْ فَرَاسِخَ، صَلَّى رَكْعَتَيْنِ»
When the Messenger of Allah (sallallahu alayhi wa sallam) went out on a journey of three miles or three Farasikh, he (sallallahu alayhi wa sallam) used to pray two Rakat. Farasikh (plural of Farsakh) is Persian unit of distance. Farsakh is equal to about three miles.