This research introduced a novel polymer synthesized by combining chitosan and modified polyvinyl alcohol, cross-linked with boric acid using dynamic covalent bonds. The polymer was developed to formulate a pregabalin Film-forming system (FFS) for treating postherpetic neuralgia via topical application, showcasing notable skin adhesion and drug delivery properites. The chitosan-boric acid-modified polyvinyl alcohol polymer was analyzed using NMR, FTIR. The exceptional features of the optimized FFS were evaluated through rheometer, Differential scanning calorimetry (Tg = 45.98 °C), contact angle (θ = 78.62°). The elongation (60.05 ± 3.67 %), cohesion (56.94 ± 4.65 MPa) and skin adhesion (58.12 ± 2.99 kPa) of chitosan-boric acid-modified polyvinyl alcohol were found to be 5.2, 6.8, and 8.3 times higher than those of the pure chitosan film, attributed to the double network structure formed by the cross-linked reversible dynamic covalent bond. The optimized pregabalin FFS exhibited increased in vitro (86.25 ± 1.87 μg/g) and in vivo (100.42 ± 7.44 μg/g) skin retention amounts compared to in vivo oral administration (28.43 ± 4.61 μg/g). In summary, the utilization of borate ester dynamic covalent bonds in developing chitosan-based film-forming polymer proved beneficial in improving skin adhesion and topical therapeutic effectiveness, thereby mitigating the risk of systemic side effects associated with oral administration.