The counterion, a negatively charged amino acid residue that stabilizes a positive charge on the retinylidene chromophore, is essential for rhodopsin to receive visible light. The counterion in vertebrate rhodopsins, Glu113 in the third transmembrane helix, has an additional role as an intramolecular switch to activate G protein efficiently. Here we show on the basis of mutational analyses that Glu181 in the second extracellular loop acts as the counterion in invertebrate rhodopsins. Like invertebrate rhodopsins, UV-absorbing parapinopsin has a Glu181 counterion in its G protein-activating state. Its G protein activation efficiency is similar to that of the invertebrate rhodopsins, but significantly lower than that of bovine rhodopsin, with which it shares greater sequence identity. Thus an ancestral vertebrate rhodopsin probably acquired the Glu113 counterion, followed by structural optimization for efficient G protein activation during molecular evolution.