To develop the next generation of high-performance robots capable of working in human environments, it is required that the joint actuators have variable stiffness to achieve both precision motion control and ability of reaction under unexpectedly huge impact caused by collision with obstacles or human. Variable stiffness actuators (VSA) partially realize such objectives by employing an auxiliary input to change the joint stiffness. However, it requires prior information of external load condition. Load sensors or online load estimation techniques need to be implemented to detect sudden unexpected load for stiffness adjustment, adding complexity to the system with bandwidth issues. In this paper, we propose a new design of compliant actuator in which the stiffness automatically varies depending on the unexpected external load. A novel doubly-clamped box structure is used to connect the load inertia to the motor inertia. Specifically, the load inertia is confined inside a box clamped by two stoppers on two opposite sides with two pre-compressed springs. A secondary motor connects to the load inertia through another spring, compensating for known unbalanced forces such as gravity, Coriolis force and inertia force. It is shown that if the unexpected external load force is below the pre-compression force of the springs, the load inertia will be confined exactly within the box and the system behaves like a rigid actuator, otherwise one of the springs will be further compressed and the system behaves like a compliant actuator. Such a mechanical structure has the ability of achieving both precision motion control and automatic reaction under unexpectedly huge external impact, without the need of additional load sensing/estimation. Control algorithms for accurate position tracking under potentially huge unexpected load is developed for this new type of actuator. Simulations are conducted to verify the effectiveness of the design concept and control.