Nanoporous boron nitride (BN) nanosheets are promising reverse-osmosis membrane materials, suitable for the removal of hazardous heavy metals, with advantages such as separation energy efficiency, eco-friendliness, heat resistance, acid resistance, and good antifouling properties. BN slit membranes (BNSMs) are a special class of nanoporous BN membranes that have not yet been extensively explored for heavy metal ion separation. To address the existing knowledge gap regarding these membranes, molecular dynamics (MD) simulations were performed herein to investigate the performance of BNSMs in purifying water from arsenic (As3+) and mercuric (Hg2+) cations, as well as chloride (Cl-) anions. For this purpose, the effects of slit width in monolayer, bilayer, and trilayer BN, interlayer distance, and membrane flexibility were evaluated. Based on the results obtained in this work, water flow rate increases, while ion rejection decreases, with increasing slit width. For rigid monolayer BNSMs having slit widths of 8–10 Å, the ion rejection percentage was in the order of As3+ > Cl- > Hg2+. The highest rejection percentage of As3+ cations in these membranes is attributed to their largest repulsive interaction energies of 27 kcal/mol with the membrane surface and the largest hydration radii of these cations (3.8 Å). For a rigid monolayer BNSM with the slit width of 7 Å, the rejection percentages of all ions were approximately equal to 100 % due to the dominant effect of slit geometric constraints against ion transport. For a rigid bilayer BNSM, both the number of filtered water molecules and water flow rate decreased with a decrease in the interlayer distance. In terms of ion rejection performance, the geometric constraints (size exclusion mechanism) were again responsible for the high (above 98 %) ion rejection percentages in these membranes with interlayer distances of 7–9 Å. Finally, flexible monolayer BNSMs were found to provide higher water flow rates and lower ion rejection percentages when compared to the rigid membranes. This behavior can be attributed to the larger slit cavity that results from membrane flexibility, thereby facilitating water flow and ion transport through the membrane. The use of molecular dynamics simulations in this study demonstrates the potential of computational methods in the design and screening of novel membrane materials, paving the way for further computational and experimental investigations in this field.