Sahl bin Saad reported,

A woman came to the Prophet ﷺ and offered herself to him in marriage. He said, "I have no need for women today."A man said, "Messenger of Allah, marry her to me."The Prophet ﷺ asked, "What do you have?"He replied, "I have nothing."The Prophet ﷺ said, "Give her something, even an iron ring."He said, "I have nothing."The Prophet ﷺ asked, "What do you know of the Quran?"He replied, "Such and such."The Prophet ﷺ said, "I have given her to you in marriage for what you know of the Quran."

Bukhari 5141

Sahih

حدثنا أبو النعمان حدثنا حماد بن زيد عن أبي حازم

عن سهل بن سعد رضي الله عنه

أن امرأة أتت النبي ﷺ فعرضت عليه نفسها فقال ما لي اليوم في النساء من حاجة فقال رجل يا رسول الله زوجنيها قال ما عندك قال ما عندي شيء قال أعطها ولو خاتما من حديد قال ما عندي شيء قال فما عندك من القرآن قال كذا وكذا قال فقد ملكتكها بما معك من القرآن

البخاري 5141صحيح
Contents
Reference
Commentary
Ayat
Collection
Sahih Bukhari
Book
Marriage
Chapter
If the suitor says to the guardian "Marry me to so-and-so" and he says "I have married her to you for such and such", the marriage is valid even if he did not say to the husband "Do you accept" or "Do you consent"
Numbering
Darussalam 5141
Bukhari 5141