"And the men seized his hand" (Genesis 19:16). They said to him: It is enough for you that you yourself are saved. Therefore they said: In the condemned city, the wealth of the righteous who are within it is lost. "the LORD being merciful unto him" (Genesis 19:16). Because the Holy One, blessed be He, had compassion upon Lot for the sake of Abraham; for when Abraham went down to Egypt, Lot did not reveal Abraham's secret — that he had said, "She is my sister." Therefore the Holy One, blessed be He, had compassion upon him and saved him. Concerning Abraham, washing is mentioned before lodging, and concerning Lot, lodging is mentioned before washing. Abraham, who was scrupulous about the filth of idolatry, placed washing before lodging; Lot, who was not scrupulous about the filth of idolatry, placed lodging before washing.
Why Lot Was Spared from Sodom for Abraham's Sake
Midrash Aggadah, Genesis 19:16
ויחזיקו האנשים בידו. אמרו לו דייך שאתה ניצול, לכך אמרו בעיר הנדחת ממון הצדיקים שבתוכה אבד: בחמלת ה' עליו. לפי שחמל הקב"ה על לוט בשביל אברהם, כי כשהלך אברהם במצרים לא גלה לוט סוד אברהם שאמר אחותי היא, לפיכך חמל עליו הקב"ה והצילו: נאמר באברהם רחיצה קודם ללינה, ובלוט נאמר לינה קודם רחיצה, אברהם שהיה מקפיד על הטנופת של ע"ז, הקדים רחיצה ללינה, לוט שלא היה מקפיד על הטנופת של ע"ז, הקדים לינה לרחיצה: