In this work, we investigate the electrical conductivity of carbon nanotubes (CNTs), with a particular focus on the effects of doping. Using first-principles-based approaches, we study the electronic structure, phonon dispersion, and electron− phonon scattering to understand the finite-temperature electrical transport properties in CNTs. Our study covers both prototypical metallic and semiconducting CNTs, with special emphasis on the influence of typical defects such as vacancies and the incorporation of copper or nitrogen, such as pyridinic N, pyrrolic N, graphitic N, and oxidized N. Our theoretical study shows significant improvements in the electrical conduction properties of copper-CNT composites, especially when semiconducting CNTs are functionalized with nitrogen. Doping is found to cause significant changes in the electronic density of states near the Fermi level, which affects the electrical conductivity. Calculations show that certain types of functional groups, such as N-pyrrolic, result in more than 30-fold increase in the conductivity of semiconducting CNTs compared to Cu-incorporated CNTs alone. For metallic CNTs, the conductivity is in agreement with existing experimental data, and our prediction of significant increases in conductivity with Npyrrolic functional group is consistent with recent experimental results, demonstrating the effectiveness of doping in modifying conductivity. Our study provides valuable insight into the electronic properties of doped CNTs and contributes to the development of ultrahigh conductivity CNT composites.