Rational structural design plays a vital role in the continuous development of electrochemical activity in glucose-oxidizing materials, which is crucial for achieving high-performance glucose sensing. Herein, a three-dimensional (3D) MgO microstructure was prepared using the hydrothermal treatment of precursors and inert gas calcination of hydrothermally produced nuclei. This 3D-MgO consisted of nanosheets with respective thicknesses and side lengths of ∼ 50 nm and ∼ 10 µm that were strongly tied together. Structural analysis demonstrated the structure’s high crystallinity and large surface area of 79.82 m2∙g−1. Moreover, Mott-Schokky and valance band analyses revealed that 3D-MgO exhibited a suitable band-edge potential for redox activity, with conduction and valence band potentials of − 2.15 and 2.29 eV, respectively. Based on these excellent characteristics, the 3D MgO was utilized as a nonenzymatic glucose-oxidizing electrode, where it exhibited high sensitivity (198 µA∙mM−1∙cm−2), a quick response time (10 s), low detection limit (0.41 µM), and a wide linear range (0.04–6.85 mM). Furthermore, it exhibited superb selectivity, repeatability, reproducibility with long-term high chemical stability, and a successful response to the glucose content present in human saliva. Due to these excellent material properties and outstanding performance in terms of glucose detection, 3D-MgO is a strong potential candidate for future research.