David dies old, and even the ending carries one more near-crisis: his son Adonijah tries to seize the throne while David is still alive but failing, and it's Bathsheba herself — the woman whose story began in David's worst sin — who goes in to remind him of his promise that Solomon would succeed him (1 Kings 1:11–31). David acts decisively one last time, has Solomon anointed immediately, and gives his son a final charge that's worth reading for its honesty about his own life: "keep the charge of the LORD thy God, to walk in his ways... that thou mayest prosper in all that thou doest" (1 Kings 2:2–3) — the same conditional language, notice, that the unconditional Davidic covenant never actually used for David's own throne, but that David still passes on as wisdom for how a son should walk regardless. He dies "in a good old age, full of days, riches, and honour" (1 Chronicles 29:28), and is buried in the city that still bears his name.