Optogenetics is a recently established neuromodulation technique in which photostimulation is used to manipulate neurons with high temporal and spatial precision. However, sequential genetic and optical insertion with double brain implantation tends to cause excessive tissue damage. In addition, the incorporation of light-sensitive genes requires the utilization of viral vectors, which remains a safety concern. Here, by combining device fabrication design, nanotechnology, and cell targeting technology, we developed a new gene-embedded optoelectrode array for neural implantation to enable spatiotemporal electroporation (EP) for gene delivery/transfection, photomodulation, and synchronous electrical monitoring of neural signals in the brain via one-time implantation. A biotic-abiotic neural interface (called PG) composed of reduced graphene oxide and conductive polyelectrolyte 3,4-ethylenedioxythiophene-modified amphiphilic chitosan was developed to form a nanostructural hydrogel with assembled nanodomains for encapsulating nonviral gene vectors (called PEI-NT-pDNA) formulated by neurotensin (NT) and polyethylenimine (PEI)-coupled plasmid DNA (pDNA). The PG can maintain high charge storage ability to respond to a minimal current of 125 μA for controllable gene delivery. The in vitro analysis of PG-PEI-NT-pDNA on the microelectrode array chip showed that the microelectrodes provided electrically inductive electropermeabilization, which permitted gene transfection into localized rat adrenal pheochromocytoma cells with a strong green fluorescent protein expression that was up to 8-fold higher than that in nontreated cells. Furthermore, the in vivo implantation enabled on-demand spatiotemporal gene transfection to neurons with 10-fold enhancement of targeting ability compared with astrocytes. Finally, using the real optogenetic opsin channelrhodopsin-2, the flexible neural probe incorporated with an optical waveguide fiber displayed photoevoked extracellular spikes in the thalamic ventrobasal region after focal EP for only 7 days, which provided a proof of concept for the use of photomodulation to facilitate neural therapies.