Both the Basic Ontological Argument and the Modal Ontological Argument Don't Succeed
They really don't
The basic version of the ontological argument is something like this.
God exists in the understanding but not in reality. (Assumption for reductio)
Existence in reality is greater than existence in the understanding alone. (Premise)
A being having all of God’s properties plus existence in reality can be conceived. (Premise)
A being having all of God’s properties plus existence in reality is greater than God. (From (1) and (2).)
A being greater than God can be conceived. (From (3) and (4).)
It is false that a being greater than God can be conceived. (From definition of “God”.)
Hence, it is false that God exists in the understanding but not in reality. (From (1), (5), (6).)
God exists in the understanding. (Premise, to which even the Fool agrees.)
Hence God exists in reality. (From (7), (8).)
6 is false. If God’s existence entails maximum greatness, then it’s not true that one can’t conceive of something greater than God. This is only true if God actually exists, which is the whole dispute in question. Premise 7 is false. This just shows that it follows from the definition of God that he actually exists. However, this doesn’t show that he actually exists. One can define a smallest actually existing martian—as Oppy has pointed out—without it being true that one of those actually exists.
One can also run a parody argument with a most perfect island, most perfect tuna salad sandwich, or most awful being (it’s more awful if it exists). Proving that God exists by definition doesn’t prove he actually exists.
Then there’s the modal ontological argument which is essentially
1 Possibly God exists
2 If God exists possibly then God exists
Therefore, God exists.
P2 is actually true because God is defined as a necessary being so if God exists in some possible worlds, he must exist in every possible world—much like the laws of logic must exist in all possible worlds if they exist in some possible worlds. However, 1 is false. While maybe a contingent version of God exists in some possible worlds, if God is defined as being necessary, then he exists in no possible world. If one can conceive of a world with no God then p1 is false because it shows that God is not possibly necessary and thus necessary.
One can also run a reverse ontological argument.
1 Possibly God doesn’t exist
2 If God possibly doesn’t exist then God doesn’t exist
Therefore, God doesn’t exist.
Much like there is no possible world in which a necessary unicorn exists, there is no possible world in which God exists. For things to be necessary in some possible worlds, there must be an explanation for why they are necessary—one that isn’t just true by definition. This is not true for God.
Lots of people have written on the subject—I haven’t time to cover it all. This, however, is the basic problem with the arguments. Versions of the argument that proceed from the definition of God to God existing are fallacious because beings defined as existing don’t actually exist necessarily. Versions that proceed from possibility (note we’re talking about metaphysical possibility) don’t work because God is not metaphysically possible if he’s defined as a necessary being any more than a necessary unicorn is.