While the seemingly obvious answer is Hester Prynne, as you so aptly have put, one must consider who is involved primarily in the climax and whose secret sin is the worst. So, it is both Reverend Dimmesdale and Roger Chillingworth whose hearts carry secret sin. But, because Chillingworth has violated "the sanctity of the human soul" his is the most heinous sin. In Chapter XIV Hester tells him,
You burrow and rankle his [Dimmesdale's] heart! Your clutch is on his life, and cause him to die daily a living death; and still he knows you not.
Thus, he should be awarded the Scarlet Letter of main characters. That is, although Dimmesdale plays the major role in the climax, Chillingworth is the main character who fulfills the theme of "The Scarlet Letter." And, he is the one who loses the most, for his soul is lost in his unrepentant hatred.
After all, there is redemption for both Hester and Dimmesdale who admit to their sins, but Chillingworth retains his sin in his black heart. Hawthorne's exhortation at the conclusion of the novel confirms this view as he expresses the "moral...from the poor minister's miserable experience":
Be true! Be true! be true! Show freely to the world, if not your worst, yet some trai whereby the worst may be inferred
With Hawthorne's theme of the greatest sin being hypocrisy, Roger Chillingworth has clearly proven himself the greatest hypocrite throughout the entire narrative. He disguises his identity, he lives with Dimmesdale under the pretense of being a physician to heal the minister, and he never confesses his sins. Instead, after rejoicing in the discovery of the letter on Dimmesdale's chest and pursuing his goal of torturing the spirit of the minister--"he will be mine"--he tells Hester that he has willingly signed on with the devil as he admits to being a fiend:
A mortal man, with once a human heart, has become a fiend for his especial torment!
And, like the Devil himself, Chillingworth, unrepentant, at the final scaffold scene,
knelt down beside him [Dimmesdale], with a blank, dull countenance, out of which the life seemed to have departed. 'Thous hast escaped me!' he repeated more thatn once 'Thou has escaped me!'
"May God forgive thee!" says the minister. "Thou, too, hast deeply sinned!"