In this paper a numerical method for an initial-boundary problem of the Rosenau-RLW equation is considered. A three-layer weighted conservative difference scheme is proposed. The scheme simulates the conservation property of the equations. The existence of discrete solution is discussed. The priori and error estimates of the discrete solution are derived, and the second order convergence and unconditional stability of the discrete solution are analyzed by the discrete energy method. Numerical examples verify the reliability of the scheme, and that the accuracy of the calculation can be improved by adjusting weighted coefficient properly.