This excerpt is taken from Sheikh Abu Hamza Abdul Khaliq Siddiqi's book Sahih Fazail-e-Amaal.
عن جابر رضى الله عنه قال: كان رسول الله صلى الله عليه وسلم يعلمنا الاستخارة فى الأمور كما يعلمنا السورة من القرآن ، يقول: إذا هم أحدكم بالأمر فليركع ركعتين من غير الفريضة ، ثم ليقل اللهم إني أستخيرك بعلمك ، وأستقدرك بقدرتك، وأسلك من فضلك العظيم، فإنك تقدر ولا أقدر ، وتعلم ولا أعلم ، وأنت علام الغيوب اللهم! إن كنت تعلم أن هذا الأمر خير لي فى ديني ومعاشي وعاقبة أمري . أو قال: عاجل أمري وآجله . فاقدره لي ويسره لي، ثم بارك لي فيه، وإن كنت تعلم أن هذا الأمر سرلي فى ديني ومعاشي وعاقبة أمري . أو قال عاجل أمري وآجله - فاصرفه عني ، واصرفني عنه واقدر لي الخير حيث كان، ثم رضني به قال: ويسمي حاجته
It is narrated from Sayyiduna Jabir رضي الله عنه that the Messenger of Allah صلی اللہ علیہ وسلم used to teach us to perform Istikhara in every matter just like the chapters of the Quran. He صلی اللہ علیہ وسلم said: "When any one of you intends to do something, he should pray two rak'ahs of prayer other than the obligatory prayers, then recite the supplication: اللهم إني أستخيرك O Allah! Indeed, I seek goodness from You through Your knowledge, and I seek power from You through Your might, and I ask You from Your great bounty, for You have power and I do not have power, You know and I do not know, and You are the Knower of the unseen. O Allah! If You know that this matter is good for me in my religion, my livelihood, and the outcome of my affairs, or (the Prophet صلی اللہ علیہ وسلم said) in terms of its delay or hastening, then decree it for me and make it easy for me, and bless me in it. And if You know that this matter is bad for me in my religion, my livelihood, and the outcome of my affairs, or (the Prophet صلی اللہ علیہ وسلم said) in terms of its delay or hastening, then turn it away from me, and turn me away from it, and decree for me what is good wherever it may be, and make me pleased with it." The Prophet صلی اللہ علیہ وسلم said: "And mention your need."
Reference: Sahih Bukhari, Book of Tahajjud, Chapter on Voluntary Prayers Two by Two, Hadith No: 1162.
Benefit: This is the Istikhara based on the teachings of the Messenger of Allah صلی اللہ علیہ وسلم, whereas nowadays people are ignorant of the Shariah teachings regarding Istikhara. In Shariah Istikhara, a person directly connects with Allah Almighty without any intermediary, but nowadays so-called clerics have opened shops for Istikhara.
Also, it is not necessary to sleep after Istikhara, nor is it necessary to have a dream or any sign. Rather, Allah Almighty strengthens the heart regarding whether the matter will happen or not.