In the present work, highly ordered TiO2 nanotube array with diameter were fabricated by one-step or two-step anodization of titanium foils. The prepared arrays were characterized by field-emission scanning electron microscopy (FESEM) and energy dispersive X-ray spectroscopy (EDX). The photocatalytic activity of the TiO2 nanotube arrays was determined by degradation of X-3B under UV and compared to direct photolysis. The results showed that its photocatalytic activity in degradation of X-3B had been dramatically enhanced as compared to direct photolysis, and the photocatalytic performance of TiO2 nanotube arrays prepared by one-step anodization was better than that made by two-step anodization. Furthermore, adsorption performance analysis suggested that the higher catalytic activity of one-step nanotube array was attributed to its larger apparent maximum number.