Carl Sagan said this quote

It is said that men may not be the dreams of the god, but rather that the gods are the dreams of men.