22 So the men turned from there and went toward Sodom, but Abraham still stood before the Lord. 23 Then Abraham drew near and said, “Will you indeed sweep away the righteous with the wicked? 24 Suppose there are fifty righteous within the city. Will you then sweep away the place and not spare it for the fifty righteous who are in it? 25 Far be it from you to do such a thing, to put the righteous to death with the wicked, so that the righteous fare as the wicked! Far be that from you! Shall not the Judge of all the earth do what is just?” 26 And the Lord said, “If I find at Sodom fifty righteous in the city, I will spare the whole place for their sake.”
27 Abraham answered and said, “Behold, I have undertaken to speak to the Lord, I who am but dust and ashes. 28 Suppose five of the fifty righteous are lacking. Will you destroy the whole city for lack of five?” And he said, “I will not destroy it if I find forty-five there.” 29 Again he spoke to him and said, “Suppose forty are found there.” He answered, “For the sake of forty I will not do it.” 30 Then he said, “Oh let not the Lord be angry, and I will speak. Suppose thirty are found there.” He answered, “I will not do it, if I find thirty there.” 31 He said, “Behold, I have undertaken to speak to the Lord. Suppose twenty are found there.” He answered, “For the sake of twenty I will not destroy it.” 32 Then he said, “Oh let not the Lord be angry, and I will speak again but this once. Suppose ten are found there.” He answered, “For the sake of ten I will not destroy it.” 33 And the Lord went his way, when he had finished speaking to Abraham, and Abraham returned to his place.
19:1 The two angels came to Sodom in the evening, and Lot was sitting in the gate of Sodom. When Lot saw them, he rose to meet them and bowed himself with his face to the earth 2 and said, “My lords, please turn aside to your servant's house and spend the night and wash your feet. Then you may rise up early and go on your way.” They said, “No; we will spend the night in the town square.” 3 But he pressed them strongly; so they turned aside to him and entered his house. And he made them a feast and baked unleavened bread, and they ate.
4 But before they lay down, the men of the city, the men of Sodom, both young and old, all the people to the last man, surrounded the house. 5 And they called to Lot, “Where are the men who came to you tonight? Bring them out to us, that we may know them.” 6 Lot went out to the men at the entrance, shut the door after him, 7 and said, “I beg you, my brothers, do not act so wickedly. 8 Behold, I have two daughters who have not known any man. Let me bring them out to you, and do to them as you please. Only do nothing to these men, for they have come under the shelter of my roof.” 9 But they said, “Stand back!” And they said, “This fellow came to sojourn, and he has become the judge! Now we will deal worse with you than with them.” Then they pressed hard against the man Lot, and drew near to break the door down. 10 But the men reached out their hands and brought Lot into the house with them and shut the door. 11 And they struck with blindness the men who were at the entrance of the house, both small and great, so that they wore themselves out groping for the door.
12 Then the men said to Lot, “Have you anyone else here? Sons-in-law, sons, daughters, or anyone you have in the city, bring them out of the place. 13 For we are about to destroy this place, because the outcry against its people has become great before the Lord, and the Lord has sent us to destroy it.” 14 So Lot went out and said to his sons-in-law, who were to marry his daughters, “Up! Get out of this place, for the Lord is about to destroy the city.” But he seemed to his sons-in-law to be jesting.
15 As morning dawned, the angels urged Lot, saying, “Up! Take your wife and your two daughters who are here, lest you be swept away in the punishment of the city.” 16 But he lingered. So the men seized him and his wife and his two daughters by the hand, the Lord being merciful to him, and they brought him out and set him outside the city. 17 And as they brought them out, one said, “Escape for your life. Do not look back or stop anywhere in the valley. Escape to the hills, lest you be swept away.” 18 And Lot said to them, “Oh, no, my lords. 19 Behold, your servant has found favor in your sight, and you have shown me great kindness in saving my life. But I cannot escape to the hills, lest the disaster overtake me and I die. 20 Behold, this city is near enough to flee to, and it is a little one. Let me escape there—is it not a little one?—and my life will be saved!” 21 He said to him, “Behold, I grant you this favor also, that I will not overthrow the city of which you have spoken. 22 Escape there quickly, for I can do nothing till you arrive there.” Therefore the name of the city was called Zoar.
23 The sun had risen on the earth when Lot came to Zoar. 24 Then the Lord rained on Sodom and Gomorrah sulfur and fire from the Lord out of heaven. 25 And he overthrew those cities, and all the valley, and all the inhabitants of the cities, and what grew on the ground. 26 But Lot's wife, behind him, looked back, and she became a pillar of salt.
27 And Abraham went early in the morning to the place where he had stood before the Lord. 28 And he looked down toward Sodom and Gomorrah and toward all the land of the valley, and he looked and, behold, the smoke of the land went up like the smoke of a furnace.
29 So it was that, when God destroyed the cities of the valley, God remembered Abraham and sent Lot out of the midst of the overthrow when he overthrew the cities in which Lot had lived. (ESV)