As a typical underactuated system, the two-wheeled self-balance robot (TWSBR) is similar to the wheeled inverted pendulum in structure. There have been plenty of studies about TWSBRs operated on the horizontal plane; however, sometimes TWSBRs need to move on non-flat ground, e.g., slopes. To tackle the control problem of TWSBRs when they move on an inclined slope, the dynamic model of TWSBRs on the slope is established in this paper. Then, the equilibrium point of the system is analyzed, and the system dynamics are expressed in the state space form. Further, the linear quadratic regulator (LQR) method is used to design a linear controller. Finally, to validate the effectiveness of the proposed controller, numerical simulation results are presented.