Debating whether it is better to be loved than to be feared is easy, finding an answer is probably infinitely hard (at the very least it is an NP-hard problem).
Niccolo Machiavelli has gotten a bum rap from history. His name has become a symbol for deviousness. In fact, Machiavelli is worth reading precisely because his view of human nature is psychologically closer to reality than the benign liberal perspective.
I think that the first and the last clause are closely related. Macchiavelli does indeed have a reputation for deviousness, but not in History, just our current history books. And that is the work of the bening liberal perspective which itself has mostly little to do with reality and everything to do with how reality should have been to suit the theory better. For quite a while he was thought to be quite a pragmatic.
An added bonus for some more historical perspective is the 1st comment, although it does get muddled towards the last third.