Leveraging recent advances in microelectromechanical system (MEMS) fabrication technologies, 100μm gap 400μm period electromagnetic undulators and 200μm gap quadrupole optics have been successfully fabricated. Measurement of the electromagnet impedance closely matches simulations, corresponding to 0.135 T peak field on-axis in the undulator and 1400 T/m field gradients in the quadrupole for the initially tested devices. These microfabricated undulators and quadrupoles are envisioned as insertion devices and focusing lattices for future compact light sources.