Formation of G-quadruplex (G4) DNA structures in key regulatory regions in the genome has emerged as a secondary structure-based epigenetic mechanism for regulating multiple biological processes including transcription, replication, and telomere maintenance. G4 formation (folding), stabilization, and unfolding must be regulated to coordinate G4-mediated biological functions; however, how cells regulate the spatiotemporal formation of G4 structures in the genome is largely unknown. Here, we demonstrate that endogenous oxidized guanine bases in G4 sequences and the subsequent activation of the base excision repair (BER) pathway drive the spatiotemporal formation of G4 structures in the genome. Genome-wide mapping of occurrence of Apurinic/apyrimidinic (AP) site damage, binding of BER proteins, and G4 structures revealed that oxidized base-derived AP site damage and binding of OGG1 and APE1 are predominant in G4 sequences. Loss of APE1 abrogated G4 structure formation in cells, which suggests an essential role of APE1 in regulating the formation of G4 structures in the genome. Binding of APE1 to G4 sequences promotes G4 folding, and acetylation of APE1, which enhances its residence time, stabilizes G4 structures in cells. APE1 subsequently facilitates transcription factor loading to the promoter, providing mechanistic insight into the role of APE1 in G4-mediated gene expression. Our study unravels a role of endogenous oxidized DNA bases and APE1 in controlling the formation of higher-order DNA secondary structures to regulate transcription beyond its well-established role in safeguarding the genomic integrity.