Erythromycin (ERY) sensor is proposed using Ag and ERY imprinted Nps layers. The sensor operates from 1.62×10−3 to 100 µM concentration. The detection limit of the sensor is 1.62×10−3 µM. The sensor shows its applicability in the real samples like milk and honey. The sensor is highly selective and sensitive with small response time.