Crosslinked network polymers have numerous important applications in engineering, biomedicine, and the environment. Establishing a crosslinked polymer network is an essential initial step toward studying the structure and function of polymer membranes. In this study, we developed a Python script named PXLink that integrates with GROMACS software to simulate the crosslinked aromatic polyamide (PA) membrane, which is widely used in desalination and water treatment. PXLink can create chemical bonds between the neighboring carboxyl and amine groups and relax the system during the crosslinking, utilizing energy minimization and molecular dynamics simulations implemented in GROMACS. The accuracy of our protocol has been successfully validated through a benchmark study of water diffusivity and the structural properties of a solvated membrane, including pore size distribution, membrane density, and the stacking of aromatic benzene rings (density profile and ordering). Moreover, the comparison between the dry and wet polymer membranes reveals that the swelling of the membrane surface leads to the expansion of subnanopores and the increased ordering of local structures. After the swelling of the membrane, the number of pores with a radius around the main region of 0.2 nm decreases, while more pores in the range of 0.22–0.38 nm are observed. There is also an increase in the orderliness of local structures, as evidenced by the increasing order parameter of aromatic ring pairs with a distance ranging from 0.7 to 0.8 nm. Our developed script will be a valuable tool for designing and discovering crosslinked polymers. Program summaryProgram Title: PXLinkCPC Library link to program files:https://doi.org/10.17632/yjw2ghfzmh.1Developer's repository link:https://github.com/zchinet30/PXLinkLicensing provisions: GNU General Public License 3Programming language: PythonNature of problem: The formation of a crosslinked polymer network is essential for theoretical studies and numerous practical applications. However, simulating the polymer crosslinking process using conventional molecular dynamic simulations presents challenges due to its intricate nature, which involves a complex interplay of physical processes and chemical reactions within a large-scale system.Solution method: To address this limitation, we developed PXLink, a python-based script, which integrates with the molecular dynamics software of GROMACS for the simulation of polymer crosslinking.