The ability to implant electronic systems in the human body has led to many medical advances. Progress in semiconductor technology paved the way for devices at the scale of a millimeter or less ("microimplants"), but the miniaturization of the power source remains challenging. Although wireless powering has been demonstrated, energy transfer beyond superficial depths in tissue has so far been limited by large coils (at least a centimeter in diameter) unsuitable for a microimplant. Here, we show that this limitation can be overcome by a method, termed midfield powering, to create a high-energy density region deep in tissue inside of which the power-harvesting structure can be made extremely small. Unlike conventional near-field (inductively coupled) coils, for which coupling is limited by exponential field decay, a patterned metal plate is used to induce spatially confined and adaptive energy transport through propagating modes in tissue. We use this method to power a microimplant (2 mm, 70 mg) capable of closed-chest wireless control of the heart that is orders of magnitude smaller than conventional pacemakers. With exposure levels below human safety thresholds, milliwatt levels of power can be transferred to a deep-tissue (>5 cm) microimplant for both complex electronic function and physiological stimulation. The approach developed here should enable new generations of implantable systems that can be integrated into the body at minimal cost and risk.