An electric drive unit for a construction machine equipped with an electricity storage device , a motor/generator which supplies and receives electric power to/from the electricity storage device , a hydraulic pump which is driven by the motor/generator , a plurality of hydraulic actuators , a plurality of operating means which command the operation of the hydraulic actuators , and a plurality of directional control valves (33, 34; 33A, 34A) which respectively control the direction and the flow rate of hydraulic fluid supplied from the hydraulic pump to the hydraulic actuators according to operating directions and operation amounts of the plurality of operating means , the electric drive unit comprising: motor/generator control means which performs variable control on the revolution speed of the motor/generator ; and command control means which calculates a command value for the motor/generator control means according to the change in a demanded flow rate determined based on operation command levels from the plurality of operating means , a plurality of pressure compensating valves (35, 36; 35A, 36A) which perform control so that differential pressure across each of the directional control valves equals load sensing differential pressure defined as differential pressure between delivery pressure of the hydraulic pump and the maximum load pressure of the hydraulic actuators ; and differential pressure detecting means (40; 40A; 40B; 40C) which detects the load sensing differential pressure, wherein: the command control means calculates the command value for the motor/generator control means according to the difference between the load sensing differential pressure detected by the differential pressure detecting means (40; 40A; 40B; 40C) and a preset target value so that the load sensing differential pressure equals the target value, and the motor/generator control means performs a regeneration control for converting the inertial force of the rotor of the motor/generator into electric power and thereby charging the electricity storage device when the revolution speed of the motor/generator is decreased in response to an excess of the load sensing differential pressure over the target value. motor/generator control means which performs variable control on the revolution speed of the motor/generator ; and command control means which calculates a command value for the motor/generator control means according to the change in a demanded flow rate determined based on operation command levels from the plurality of operating means , a plurality of pressure compensating valves (35, 36; 35A, 36A) which perform control so that differential pressure across each of the directional control valves equals load sensing differential pressure defined as differential pressure between delivery pressure of the hydraulic pump and the maximum load pressure of the hydraulic actuators ; and differential pressure detecting means (40; 40A; 40B; 40C) which detects the load sensing differential pressure, the command control means calculates the command value for the motor/generator control means according to the difference between the load sensing differential pressure detected by the differential pressure detecting means (40; 40A; 40B; 40C) and a preset target value so that the load sensing differential pressure equals the target value, and the motor/generator control means performs a regeneration control for converting the inertial force of the rotor of the motor/generator into electric power and thereby charging the electricity storage device when the revolution speed of the motor/generator is decreased in response to an excess of the load sensing differential pressure over the target value. <EOS>