Inspired by biological channels, achieving precise separation of ion/water and ion/ion requires finely tuned pore sizes at molecular dimensions and deliberate exposure of charged groups. Covalent organic frameworks (COFs), a class of porous crystalline materials, offer well-defined nanoscale pores and diverse structures, making them excellent candidates for nanofluidic channels that facilitate ion and water transport. In this study, we perform molecular simulations to investigate the structure and kinetics of water and ions confined within the typical COFs with varied exposure of charged groups. The COFs exhibit vertically arrayed nanochannels, enabling diffusion coefficients of water molecules within COFs to remain within the same order of magnitude as in the bulk. The motion of water molecules manifests in two distinct modes, creating a mobile hydration layer around acid groups. The ion diffusion within COFs displays a notable disparity between monovalent (M+) and divalent (M2+) cations. As a result, the selectivity of M+/M2+ can exceed 100, while differentiation among M+ is less pronounced. In addition, our simulations indicate a high rejection (R > 98%) in COFs, indicating their potential as ideal materials for desalination. The chemical flexibility of COFs indicates that would hold significant promise as candidates for advanced artificial ion channels and separation membranes.