Pharmacology and optogenetics are widely used in neuroscience research to study the central and peripheral nervous systems. While both approaches allow for sophisticated studies of neural circuitry, continued advances are, in part, hampered by technology limitations associated with requirements for physical tethers that connect external equipment to rigid probes inserted into delicate regions of the brain. The results can lead to tissue damage and alterations in behavioral tasks and natural movements, with additional difficulties in use for studies that involve social interactions and/or motions in complex 3-dimensional environments. These disadvantages are particularly pronounced in research that demands combined optogenetic and pharmacological functions in a single experiment. Here, we present a lightweight, wireless, battery-free injectable microsystem that combines soft microfluidic and microscale inorganic light-emitting diode probes for programmable pharmacology and optogenetics, designed to offer the features of drug refillability and adjustable flow rates, together with programmable control over the temporal profiles. The technology has potential for large-scale manufacturing and broad distribution to the neuroscience community, with capabilities in targeting specific neuronal populations in freely moving animals. In addition, the same platform can easily be adapted for a wide range of other types of passive or active electronic functions, including electrical stimulation.