Size selectivity is an important mechanism for molecular recognition based on the size difference between targets and non-targets. However, rational design of an artificial sizeselective molecular recognition system for biological targets in living cells remains challenging. Herein, we construct a DNA molecular sieve for size-selective molecular recognition to improve the biosensing selectivity in living cells. The system consists of functional nucleic acid probes (e.g., DNAzymes, aptamers and molecular beacons) encapsulated into the inner cavity of framework nucleic acid. Thus, small target molecules are able to enter the cavity for efficient molecular recognition, while large molecules are prohibited. The system not only effectively protect probes from nuclease degradation and nonspecific proteins binding, but also successfully realize size-selective discrimination between mature microRNA and precursor microRNA in living cells. Therefore, the DNA molecular sieve provides a simple, general, efficient and controllable approach for size-selective molecular recognition in biomedical studies and clinical diagnoses.