The Messenger of Allah ﷺ said, "Whoever seeks it out, let him seek it on the twenty-seventh night." He also said, "Seek it on the twenty-seventh night," meaning Laylat al-Qadr.
قال رسول الله ﷺ: من كان متحريها، فليتحرها ليلة سبع وعشرين. وقال: تحروها ليلة سبع وعشرين يعني ليلة القدر.
Imam Ahmad narrated it (4808) from Yazid bin Harun, who said, Shuba informed us, from Amr bin Dinar, from Ibn Umar, and he mentioned it. Its chain of transmission is sahih.Abu Dawud Tayalisi also narrated it (2000) from Shuba in similar fashion.Malik narrated it, and through his route Muslim (1165:206) narrated it from Abdullah bin Dinar, with the wording, "Seek out Laylat al-Qadr in the last seven nights," as will come later. This appears to be the correct version, as Ahmad narrated it (6474). Abdullah said, I read this hadith to my father and I also heard it directly from him. He said, Aswad bin Amir told us, Shuba told us, Abdullah bin Dinar told me, he said, I heard Ibn Umar relating from the Prophet ﷺ concerning Laylat al-Qadr, that he said, "Whoever wants to seek it out should seek it on the night of the twenty-seventh."Shuba said, A trustworthy man mentioned to me, from Sufyan, that he used to say, He only said, "Whoever wants to seek it out should seek it in the last remaining seven nights." Shuba said, I do not know whether it was this or that, Shuba was uncertain.Abdullah bin Ahmad said, My father said, The trustworthy man was Yahya bin Saeed Qattan.