We (i.e., the US/the internet) have a tendency to view basic human rights through a very US-centric framework. We value freedom of speech above all else (well except the right to bear/bare arms...). However, our framework of what rights there should be is not entirely universal, nor should it be. We tend to be not so great at articulating a basic right to exist or to be free from harm created by others. I hear many conversations about the constitution, which is our law, but I rarely hear people discuss the declaration of independence which was a much broader statement about the rights of human beings. The constitution is our codification and does not, nor should it, be applied as a universal critique of other systems.
And none of that is to say that we have unlimited free speech anyways in the US. The standard framework for restriction is strict scrutiny, which requires a compelling governmental interest to restrict free speech (e.g., preserving the health and welfare of many citizens is why you can't yell fire in a crowded theater). Because the law is not ahistorical, I think you could make a fairly compelling argument that it is in the German government's interest to make laws that do things like make denying the holocaust illegal or placing some limits on hate speech. The potential damage of those things is something that Germany has experienced in ways we haven't, and I would generally defer to them making laws within their own society rather than judge them with ours.