Abstract. In this work the effect of doping with aluminum (Al) and boron (B) an armchair (6,6) carbon nanotube on its sensibility to carbon dioxide (CO2) for possible application in sensors of this gas was studied. Using firstprinciples calculations within the framework of the density functional theory (DFT), adsorption energies were obtained in the cases when the molecule is initially perpendicular to the surface of the nanotube, near the dopant atom, and located above a carbon atom of the nanotube, above a C-C bond, or directly above the center of a hexagon. It was found that doping with Al does not improve the adsorption of the molecule compared to the pristine nanotube. However, doping with B slightly favors the adsorption for some of the considered positions. The results suggest that B doping might be an acceptable option in the design and construction of nano devices for CO2 detection.