Multi-walled carbon nanotubes (MWCNTs) encapsulated by polyaniline (PANI) were synthesized by in situ polymerization. Scanning electron microscopy (SEM), Fourier transform infrared (FT-IR) spectroscopy and thermal gravimetric analysis (TGA) were used to characterize the synthesized composites (O-MWCNTs/PANI), and the surface area was calculated by the Brunauer–Emmett–Teller (BET) method. The removal capacity of alizarin yellow R (AYR) with O-MWCNTs/PANI was further investigated. Experiments were conducted to optimize the adsorption conditions, including contact time, pH, initial concentration of AYR and temperature. The results showed that the maximum adsorption capacity for AYR was 884.80 mg/g. The adsorption kinetics and the adsorption isotherm could be better described by the pseudo-second-order model and the Langmuir isotherm, respectively. Energy changes revealed that the adsorption process was exothermic and spontaneous in nature. Additionally, the O-MWCNTs/PANI showed higher adsorption capacity than pristine MWCNTs or PANI. Therefore, O-MWCNTs/PANI would be applied as an efficient adsorbent for the removal of dye from water.