Traditional upper limb rehabilitation robots can only complete rehabilitation training according a predetermined trajectory, and its safety system is unreliable, the movement status of the affected limb cannot be adjusted or trained according to the expected torque of the human body. This study presents a flexible safety system for the rehabilitation of joints based on magnetorheological (MR) fluid. First of all, the MR dampers inverter has the advantages of large torque, fast response, controllable flexibility, and safety assurance. The range of motion tracks can be adjusted through the four-lever hinge mechanism, and the required driving force is provided by the motor actuator, and MR damper provides flexibility and variable damping characteristics for the output torque. The system adopts the force/position impedance safety control method, under the action of the internal position closed-loop controller, the MR upper limb rehabilitation flexible joint drives the affected limb to track to the safe position and carries out simulation to verify the accuracy of the system motion torque and position. The safe rehabilitation effect of the upper limb rehabilitation system under the three working conditions (Step, Incremental and Equation) of the interaction moment of the affected limb has been extensively studied. The simulation and experiment results show that the MR damper can control the upper limb rehabilitation system to achieve the desired effect under the condition of increasing and changing the interactive force of the patient, and the safety design of the upper limb rehabilitation robot based on MR is verified.