Note that its all in the context of feudalism not a republic.
Niccolo identifies that a successful ruler generally does things that lead to the success of the principality. And that usually involves letting people do what they want. Rule by menace or despotism is not a long-term policy as ultimately the mob will support a usurper.
So pegging Machiavelli as some evil demon is lazy and inaccurate.
That is entirely correct. Machiavelli was a small-R republican, said so at length in the Discourses, and ended up getting tortured by the Medici for his activities defending the Republic of Florence from their reoccupation. The model for The Prince was Cesare Borgia, who all Machiavelli's readers knew perfectly well came to a rather bad end 25 years before The Prince was published. That context isn't very clear some 490 years afterward but it was clear at the time.
I never pegged Niccolo is a “bad guy”. This needs to be read to understand how to take and consolidate power. And it was dedicated to the Medicis. The global bankers of his time.