In this paper, the effect of boundary layer excitation on increasing the heat transfer coefficient of water/carbon nanotube (CNT) nanofluid and water/aluminum oxide (Al2O3) nanoparticles has been investigated. The turbulent flow equations inside the pipe with RNG K-ε turbulence model are solved employing fluent software. The results show that the use of water/CNT nanofluid significantly increases the heat transfer coefficient of the convection. There is no such increase for water-aluminum oxide nanoparticles. If the volumetric percentage of the carbon nanotube increases, the rate of increase in the heat transfer coefficient and the flow pressure drop will increase. Therefore, the use of water/CNT nanofluid with lower volumetric percentages is better for improving the convective heat transfer. Also, by placing the barrier on the inner wall of the tube and stimulating the boundary layer, the heat transfer coefficient thereafter increases in the excitement area. In the present study, the use of three obstacles behind each other has increased the average heat transfer coefficient by 16.7%.