Al-doped ZnO (AZO) thin films are effective n-type semiconductors for ultraviolet (UV) detection because of their low cost, high electron mobility, and high sensitivity to UV light, especially in the UVA spectrum. However, a reasonable compromise between performance (such as sensitivity, detectivity, and response time) and fabrication ease remains an obstacle to the practicability of AZO-based UV photodetectors. To address this issue, we propose an efficient strategy to achieve a large AZO photoactive area for outstanding performance, along with a facile sol−gel method. Consequently, the device exhibits a superb on/off ratio of >10 4 , a high detectivity of 1.85 × 10 12 Jones, and a fast response speed under 365 nm UVA illumination without external energy consumption. Hence, this study suggests a selfpowered and high-performance nanoporous AZO-based UVA detector with an environmentally friendly scalable process that satisfies industrial production requirements for numerous practical UV-detection applications.