DNA and RNA analysis is of high importance for clinical diagnoses, forensic analysis, and basic studies in the biological and biomedical fields. In this paper, we report the ultrahighly sensitive homogeneous detection of DNA and microRNA by using a novel single-silver-nanoparticle counting (SSNPC) technique. The principle of SSNPC is based on the photon-burst counting of single silver nanoparticles (Ag NPs) in a highly focused laser beam (about 0.5 fL detection volume) due to Brownian motion and the strong resonance Rayleigh scattering of single Ag NPs. We first investigated the performance of the SSNPC system and then developed an ultrasensitive homogeneous detection method for DNA and microRNA based on this single-nanoparticle technique. Sandwich nucleic acid hybridization models were utilized in the assays. In the hybridization process, when two Ag-NP–oligonucleotide conjugates were mixed in a sample containing DNA (or microRNA) targets, the binding of the targets caused the Ag NPs to form dimers (or oligomers), which led to a reduction in the photon-burst counts. The SSNPC method was used to measure the change in the photon-burst counts. The relationship between the change of the photon-burst counts and the target concentration showed a good linearity. This method was used for the assay of sequence-specific DNA fragments and microRNAs. The detection limits were at about the 1 fM level, which is 2–5 orders of magnitude more sensitive than current homogeneous methods.