Friedrich Nietzsche said this quote

The believer in magic and miracles reflects on how to impose a law on nature--: and, in brief, the religious cult is the outcome of this reflection.