2 Samuel 24:11

11And when David arose in the morning, the word of the Lord came to athe prophet Gad, David’s bseer, saying,

1 Chronicles 21:18-30

David Builds an Altar

18Now cthe angel of the Lord had commanded Gad to say to David that David should go up and raise an altar to the Lord on the threshing floor of Ornan the Jebusite. 19So David went up at Gad’s word, which he had spoken in the name of the Lord. 20Now Ornan was threshing wheat. He turned and saw the angel, and his four sons who were with him hid themselves. 21As David came to Ornan, Ornan looked and saw David and went out from the threshing floor and paid homage to David with his face to the ground. 22And David said to Ornan, “Give me the site of the threshing floor that I may build on it an altar to the Lordgive it to me at its full price—that the plague may be averted from the people.” 23Then Ornan said to David, “Take it, and let my lord the king do what seems good to him. See, I give the oxen for burnt offerings and the threshing sledges for the wood and the wheat for a grain offering; I give it all.” 24But King David said to Ornan, “No, but I will buy them for the full price. I will not take for the Lord what is yours, nor offer burnt offerings that cost me nothing.” 25So David paid Ornan d600 shekels
A  shekel was about 2/5 ounce or 11 grams
of gold by weight for the site.
26And David built there an altar to the Lord and presented burnt offerings and peace offerings and called on the Lord, and the Lord
Hebrew he
ganswered him with fire from heaven upon the altar of burnt offering.
27Then the Lord commanded the angel, and he put his sword back into its sheath.

28At that time, when David saw that the Lord had answered him at the threshing floor of Ornan the Jebusite, he sacrificed there. 29For the tabernacle of the Lord, which Moses had made in the wilderness, and the altar of burnt offering hwere at that time in the high place at Gibeon, 30but David could not go before it to inquire of God, for he was afraid of the sword of the angel of the Lord.

Copyright information for ESV