Abstract The molecular simulation technique was adopted to investigate the structure and transport performance of thermally rearranged poly(benzoxazole-co-imide) membranes. A molecular dynamics (MD) technique was used to construct three models: a poly-benzoxazole (PBO) membrane with high free volume; a polyimide (PI) membrane with dense structure; and their co-polymer, PBO-PI membrane. The MD simulation was performed to characterize the membrane models to understand how the very rigid benzoxazole segments affect the micro-structure, free volume, cavity size, and gas diffusion of the membrane models. A Monte Carlo method was adopted to investigate the gas sorption behaviors in the three types of membranes. The torsional angle and wide-angle X-ray diffraction analyses suggest that the benzoxazole segments stiffened the polymeric chains, leading to the formation of a looser structure. In free-volume and cavity-size studies, the PBO membrane exhibited the highest free volume and largest cavity size, which can be attributed to the presence of the benzoxazole structure constructed by thermal rearrangement. The enlarged free volume in the membranes with benzoxazole segments provided more space for gas sorption and diffusion, which effectively enhanced the gas permeability. In addition, increasing the benzoxazole segments in the membrane structure enhances the gas sorption in accordance with Henry's law, as the PBO membrane provides more inter-polymeric chain space and allows for the larger free volume elements. Fabrication of the poly(benzoxazole-co-imide) membrane with an appropriate PBO/PI composition would help optimize the gas permeability and selectivity in the gas separation process. The results from the simulation agree with the experimental data, indicating that the molecular simulation technique is a useful method in the field of materials design and development for the membrane separation process.