It was French philosopher and Renaissance man René Descartes who famously said "Je pense, donc je suis," better known as "Cogito, ergo sum," and best known by English speakers as "I think, therefore I am." What Descartes had reasoned out was that by the very act of thinking, he was participating in some version of some reality somewhere.
Furthermore, Descartes realized his thinking was part of whatever reality he was participating in. That is, there existed at least one reality that included René Descartes thinking.
But what about this? Was there any reality, anywhere, at any time that didn't include René Descartes thinking? If not—if all realities always included René Descartes thinking—then Descartes reasoned he would have to be his own causal agent, meaning he was the creator of all possible realities. Said another way, there is no reality that exists unless Descartes thinks.
But if there exists one or more realities in which Descartes isn't thinking, then something (or someone) other than Descartes must be the causal agent for that reality (or those realities). And Descartes reasoned that causal agent would necessarily have to be God.
Finally, Descartes was able to rule out the first possibility—that he was the creator of all realities—because he wasn't completely independent of his reality. That is, he was a being that needed to be sustained by his reality. For example, he needed oxygen, food, water, and rest.
Thus, Descartes used reason and logic to show that God must exist—at least in those realities in which Descartes wasn't thinking.
So what's the application for us? If we don't think God exists, we should try an experiment—let's just stop thinking. If reality ceases to exist, then okay—there is no God. Otherwise, if reality continues to exist even when we stop thinking, then God must exist. So think about that.