C-3PO is an interesting character. In many ways, he holds the same thematic position in the original Star Wars trilogy that Jar-Jar Binks held in The Phantom Menace. But while Binks is almost universally reviled for his role as bumbling comic relief, C-3PO is mostly seen as an endearing character despite also providing bumbling comic relief. One might even say that the love for C-3PO contributed to the decision to include Binks in the prequels. So why did the one character end up being loved while the other is hated? In short, what went wrong?
The answer to that question lies, I think, in understanding why people liked C-3PO in the original set of films. He was a mostly incompetent clown for much of the movies, stumbling about in situations that he was clearly not equipped to handle. He found himself in the middle of space battles, wandering through the desert, or getting lost in unfamiliar cities, often turning out to be a useless burden to his companions. But he's not completely useless: As he tells Luke's Uncle Owen, he's programmed as a translator, with the ability to converse in thousands of languages. He is woven into the plot as a necessary element, serving as a sidekick and counterpoint to R2-D2 for much of the first movie, a foil for Han Solo for the bulk of the second, and and unexpectedly critical member of the raiding party in the third. He wasn't very good at most things, but he tried to be helpful anyway and succeeded often enough to offset his general incompetence.
C-3PO also had the advantage of reminding people of a mildly prissy gentleman rather than a vaguely racist caricature with a propensity for fart and burp jokes. C-3PO's humor was often drawn from the fact that he was a fish out of water - a non-adventurous personality trapped in an almost unceasing adventure, but who accompanies the heroes because he has at least one skill they don't. Binks, by contrast, spends most of his time being a careless nuisance that the main characters bring with them for almost inexplicable reasons and whose only useful moments are entirely accidental. We like C-3PO even though he's incompetent because he knows he's not good at being a swashbuckling adventurer but tries his best. We loathe Jar-Jar Binks because he's an idiot who doesn't realize he's an idiot.
Note: C-3PO in the later prequels Attack of the Clones and Revenge of the Sith becomes far less likable. This is probably because he starts to act a lot more like Jar-Jar Binks did in The Phantom Menace.
The Doubleclicks Musical Monday Home