Nietzsche is often taken as a poster-boy for atheism due to his infamous phrase, “God is dead!” However, that is not a clear endorsement of atheism but rather, theothanatology. In his writings, Nietzsche did refer to atheism and oftentimes in jest. His hermeneutic-psychoanalysis of Christianity led him to be exceedingly critical of atheists, as well as scientists and skeptics. This was due to Christianity and science’s obsession with truth in the objective & universal sense. This dates back to Plato (“truth is divine”), which became mutated to new heights by the religious fervor in Judaism & Christianity that equated God with truth.
Older civilizations (Hellenic Greeks) did not revere truth in the same way, for they instead esteemed beauty and human achievements (courage, glory excellence). The ascetic ideals of slave morality and Christianity devalued these accomplishments for the sake of objective & universal truths.
That the skeptics, scientists and atheists remain obsessed with truth leads Nietzsche to scorn them as the latest and greatest variants of the ascetic ideal that attempts to sacrifice the subjective expression of the will to power for some universally binding concept of truth. (Genealogy of Morals 3.27)
Although the inherent logic of Western religion resulted in atheism due to the will to truth, that logic also hints at something further down the road than modern atheism: a post-nihilistic possibility where religion is generated by philosophy or a religion that is spiritually harmonious with philosophy. (Beyond Good & Evil 55-57)