In this article, we have demonstrated a universal method for improving the stability of polyelectrolyte multilayer films by designing a photoreactive polyanion as the building block for layer-by-layer (LbL) self-assembly. By grafting an azido group into poly(acrylic acid), we synthesized a photoreactive polyanion, which can induce the photo-cross-linking between the azido group and polymeric backbone under UV irradiation. Our results show that after photo-cross-linking, the stability of the polyelectrolyte multilayer is greatly improved. Considering that the polyanion-bearing azido group is highly reactive, we have shown that it can be used to stabilize different LbL films. Moreover, by taking advantage of the different stability before and after UV irradiation, a patterned surface can be fabricated, which could be used as a template for selective adsorption.