We investigate Sarnak's M\"obius Disjointness Conjecture through asymptotically periodic functions. It is shown that Sarnak's conjecture for rigid dynamical systems is equivalent to the disjointness of M\"obius from asymptotically periodic functions. We give sufficient conditions and a partial answer to the later one. As an application, we show that Sarnak's conjecture holds for a class of rigid dynamical systems, which improves an earlier result of Kanigowski-Lema{\'{n}}czyk-Radziwi{\l}{\l}.