We describe ultrasonic‐assisted dispersive solid‐phase extraction based on ion‐imprinted polymer (UA‐DSPE‐IIP) nanoparticles for the selective extraction of silver ions. Ultrasound is a good and robust method to facilitate the extraction of target ions in the sorption step and elution of the target ions in the desorption step. The IIP nanoparticles used in the UA‐DSPE‐IIP were prepared by precipitation polymerization. To prepare the IIP nanoparticles, 2‐vinylpyridine, ethylene glycol dimethacrylate, 2,2′‐azobisisobutyronitrile, 2‐picolinic acid, silver and chloroform–methanol (50:50) solution were used as functional monomer, cross‐linker, initiator, silver‐binding ligand, template ion and porogen, respectively. The IIP nanoparticles were characterized using Fourier transformed infrared spectroscopy, thermogravimetric and differential thermal analysis, X‐ray diffraction and scanning electron microscopy. A Box–Behnken design was used for optimization of sorption and desorption steps in UA‐DSPE‐IIP. In the sorption step: pH of solution, IIP amount (mg), sonication time for sorption (min); in the desorption step: concentration of eluent (mol l−1), volume of eluent (ml), sonication time (min) for desorption were investigated and optimized by Box–Behnken design. The optimum conditions for the method were: pH of solution, 7; sonication time for sorption, 7 min; IIP amount, 17 mg; type and concentration of eluent, HCl 1.5 mol l−1; volume of eluent, 2 ml; sonication time for desorption, 140 s. Under the optimized conditions the limit of detection and relative standard deviation for the detection of silver ions using UA‐DSPE‐IIP were found to be 0.09 μg l−1 and <3%, respectively.