The selective functionalization of strong, typically inert carbon-hydrogen (C-H) bonds in organic molecules is changing synthetic chemistry. However, the undirected functionalization of primary C-H bonds without competing functionalization of secondary C-H bonds is rare. The borylation of alkyl C-H bonds has occurred previously with this selectivity, but slow rates required the substrate to be the solvent or in large excess. We report an iridium catalyst ligated by 2-methylphenanthroline with activity that enables, with the substrate as limiting reagent, undirected borylation of primary C-H bonds and, when primary C-H bonds are absent or blocked, borylation of strong secondary C-H bonds. Reactions at the resulting carbon-boron bond show how these borylations can lead to the installation of a wide range of carbon-carbon and carbon-heteroatom bonds at previously inaccessible positions of organic molecules.