Programmable magnetic soft grippers are highly desirable for diverse applications in drug delivery, object manipulation, and soft robotics. However, current magnetic programming grippers need to be driven by multiple physical fields, which are complicated to operate and single in motion. Here, a method for patterning hard magnetic microparticles in an elastomer matrix is reported. Based on digital light processing (DLP), this method uses controlled reorientation of magnetic particles and selective exposure to ultraviolet (UV) light to encode magnetic particles in polydimethylsiloxane (PDMS) materials with arbitrary three‐dimensional (3D) orientation. The combination of vertical and horizontal magnetic fields can produce different forces, causing different deformation modes of the grippers. Flexible grippers can be fabricated from a single precursor in one process and produce various deformation and motion forms when a single magnetic field is applied. Moreover, the gripper has the advantages of simple manipulation, fast response, and flexible movement, which is of great significance in the application of biological devices and soft robots.