From Nietzsche, Twilight of the Idols (1889):
My conception of freedom. -- The value of a thing sometimes does not lie in that which one attains by it, but in what one pays for it -- what it costs us. I shall give an example. Liberal institutions cease to be liberal as soon as they are attained: later on, there are no worse and no more thorough injurers of freedom than liberal institutions. Their effects are known well enough: they undermine the will to power; they level mountain and valley, and call that morality; they make men small, cowardly, and hedonistic -- every time it is the herd animal that triumphs with them. Liberalism: in other words, herd-animalization.
These same institutions produce quite different effects while they are still being fought for; then they really promote freedom in a powerful way. On closer inspection it is war that produces these effects, the war for liberal institutions, which, as a war, permits illiberal instincts to continue. And war educates for freedom. For what is freedom? That one has the will to assume responsibility for oneself. That one maintains the distance which separates us. That one becomes more indifferent to difficulties, hardships, privation, even to life itself. That one is prepared to sacrifice human beings for one's cause, not excluding oneself. Freedom means that the manly instincts which delight in war and victory dominate over other instincts, for example, over those of "pleasure." The human being who has become free -- and how much more the spirit who has become free -- spits on the contemptible type of well-being dreamed of by shopkeepers, Christians, cows, females, Englishmen, and other democrats. The free man is a warrior.
How is freedom measured in individuals and peoples? According to the resistance which must be overcome, according to the exertion required, to remain on top. The highest type of free men should be sought where the highest resistance is constantly overcome: five steps from tyranny, close to the threshold of the danger of servitude. [...] This is true politically too; one need only go through history. The peoples who had some value, attained some value, never attained it under liberal institutions: it was great danger that made something of them that merits respect. Danger alone acquaints us with our own resources, our virtues, our armor and weapons, our spirit, and forces us to be strong. First principle: one must need to be strong -- otherwise one will never become strong.
(Illustration is John Henry Fuseli, Odysseus before Scylla and Charybdis, 1794-96.)