The following spring, the time of year when kings go to war, David sent Joab and the Israelite army to destroy the Ammonites. In the process they laid siege to the city of Rabbah. But David stayed behind in Jerusalem.
Late one afternoon David got out of bed after taking a nap and went for a stroll on the roof of the palace. As he looked out over the city, he noticed a woman of unusual beauty taking a bath.
He sent someone to find out who she was, and he was told, "She is Bathsheba, the daughter of Eliam and the wife of Uriah the Hittite."
Then David sent for her; and when she came to the palace, he slept with her. (She had just completed the purification rites after having her menstrual period.) Then she returned home.
Later, when Bathsheba discovered that she was pregnant, she sent a message to inform David.
So David sent word to Joab: "Send me Uriah the Hittite."
When Uriah arrived, David asked him how Joab and the army were getting along and how the war was progressing.
Then he told Uriah, "Go on home and relax." David even sent a gift to Uriah after he had left the palace.
But Uriah wouldn't go home. He stayed that night at the palace entrance with some of the king's other servants.
When David heard what Uriah had done, he summoned him and asked, "What's the matter with you? Why didn't you go home last night after being away for so long?"
Uriah replied, "The Ark and the armies of Israel and Judah are living in tents, and Joab and his officers are camping in the open fields. How could I go home to wine and dine and sleep with my wife? I swear that I will never be guilty of acting like that."
References for 2 Samuel 11:11
"Well, stay here tonight," David told him, "and tomorrow you may return to the army." So Uriah stayed in Jerusalem that day and the next.
Then David invited him to dinner and got him drunk. But even then he couldn't get Uriah to go home to his wife. Again he slept at the palace entrance.
So the next morning David wrote a letter to Joab and gave it to Uriah to deliver.
The letter instructed Joab, "Station Uriah on the front lines where the battle is fiercest. Then pull back so that he will be killed."
So Joab assigned Uriah to a spot close to the city wall where he knew the enemy's strongest men were fighting.
And Uriah was killed along with several other Israelite soldiers.
Then Joab sent a battle report to David.
He told his messenger, "Report all the news of the battle to the king.
But he might get angry and ask, 'Why did the troops go so close to the city? Didn't they know there would be shooting from the walls?
Wasn't Gideon's son Abimelech killed at Thebez by a woman who threw a millstone down on him?' Then tell him, 'Uriah the Hittite was killed, too.'"
References for 2 Samuel 11:21
So the messenger went to Jerusalem and gave a complete report to David.
"The enemy came out against us," he said. "And as we chased them back to the city gates,
the archers on the wall shot arrows at us. Some of our men were killed, including Uriah the Hittite."
"Well, tell Joab not to be discouraged," David said. "The sword kills one as well as another! Fight harder next time, and conquer the city!"
When Bathsheba heard that her husband was dead, she mourned for him.
When the period of mourning was over, David sent for her and brought her to the palace, and she became one of his wives. Then she gave birth to a son. But the LORD was very displeased with what David had done.