Methods to manipulate magnetic beads are essential factors to determine the efficiency and dimension of an in vitro diagnostic system. Currently, using movable permanent magnets and planar electromagnets is still the major approach to achieve magnetic bead control, causing significant constraint in the miniaturization of in vitro diagnostic systems. Here, we propose techniques to construct a fully integrated microfluidic device that can conduct automatic magnetic bead manipulation as well as rapid chemical reaction and cleaning in a minimized dimension similar to a USB disk. The device combines the precision control of multiple electromagnetic coils with the compactness of microfluidic channels, leading to one of the smallest automatic magnetic bead manipulation systems that can complete several major magnetic bead-based operation steps such as sample injection, reaction, cleaning, and collection. The influencing factors such as coil driving parameters, surface treatment of the microchannels, and properties of magnetic particles have also been investigated to optimize the device performance. The device can drive mixtures of Fe3O4 microparticles and polymer magnetic beads (PMBs) with a weight ratio of 1:1 at a maximum speed of 0.5 cm·s-1 and reduce the time for DNA binding and dissociation reactions from 20 min to only 48 s. This device has significantly advanced the conventional manipulation methods of magnetic beads and has demonstrated the possibility to construct an automatic and ultraminiaturized in vitro diagnostic system that may facilitate portable or even wearable chemical analysis.