Hydraulic actuating system exhibits potential for legged robots to achieve highly agile dynamic movement because of their high power-to-weight ratio. However, the low energy efficiency of the hydraulic system can reduce the operating time and cause heat dissipation. In this article, an optimal control framework based on the model predictive control (MPC) is proposed to improve energy efficiency and provide robust supply of pressure required for robot tasks. The MPC includes the power loss function and supply pressure regularization term as the cost function and limitation on the pump speed and acceleration as the constraints. When implemented to the hydraulic biped robot, LIGHT, the proposed method allows legged robots to achieve the commanded motion without losing balance while minimizing energy consumption. The energy saving performance of the proposed method with MPC is also validated via simulation and experiment.