Create in me a clean heart, O God; i.e. do more than purify me—do more than cleanse me (Psalms 51:7); by an act of creative power ( בּרא) make in me a new clean heart. Compare the Christian doctrine of the "new birth" and "new life."
And renew a right spirit within me. "Heart" and "spirit" are used interchangeably for the inward essence of man; but, as Professor Cheyne observes, "Heart emphasizes the individual side of a man's life; spirit, its Divine, or at least preternatural side."
David, in asking both for a new heart and a new spirit, requests the renovation of his entire mental and moral nature, which he recognizes as corrupt and depraved.