We propose a protocol for coherently transferring non-Gaussian quantum states from an optical field to a mechanical oscillator. We demonstrate its experimental feasibility in future gravitational-wave detectors and tabletop optomechanical devices. This work not only outlines a feasible way to investigate nonclassicality in macroscopic optomechanical systems, but also presents a new and elegant approach for solving non-Markovian open quantum dynamics in general linear systems.