Sunan an-Nasa'i, Book 22, Hadith 245 (In-Book) ⓘ
It was narrated from Hafsah that the Prophet said: "Whoever does not have the intention of fasting from the night before, then there is no fast for him." (Daif)
أَخْبَرَنَا أَحْمَدُ بْنُ الأَزْهَرِ، قَالَ حَدَّثَنَا عَبْدُ الرَّزَّاقِ، عَنِ ابْنِ جُرَيْجٍ، عَنِ ابْنِ شِهَابٍ، عَنْ سَالِمٍ، عَنِ ابْنِ عُمَرَ، عَنْ حَفْصَةَ، أَنَّ النَّبِيَّ صلى الله عليه وسلم قَالَ " مَنْ لَمْ يُبَيِّتِ الصِّيَامَ مِنَ اللَّيْلِ فَلاَ صِيَامَ لَهُ " .
also referenced under: Hadith 2334 (Reference) & Volume 3, Book 22, Hadith 2336 (DarusSalam)