The invention discloses an energy regeneration system of an excavator and the excavator. The system comprises a main hydraulic oil line, a pilot hydraulic oil line, a pilot pump, a first pump, a second pump, an engine, a first sensor, a second sensor, an electromagnetic valve, a main controller, an operation handle, a movable arm oil cylinder, a first movable arm valve core, a first stick valve core, a switch valve, a one-way valve, a second stick valve core, a second movable arm valve core, a stick oil cylinder and a hydraulic oil tank, wherein the pilot pump, the first pump, the second pump and the engine are sequentially connected, the first pump is connected with the main controller through the first sensor, the second pump is connected with the main controller through the second sensor, the first stick valve core is respectively connected with the second pump, the second movable arm valve core and the one-way valve, the one-way valve, the switch valve and the first movable arm valve core are sequentially connected, and the movable arm oil cylinder is sequentially connected with the second movable arm valve core and the first movable arm valve core. The system has the advantages that the working efficiency of the excavator is improved, the fuel consumption is reduced, and the operation convenience of the integral excavator is improved.