Protamine (PA) is the only licensed antidote for reversing heparin anticoagulation by electrostatically binding with heparin. Efforts have been made on designing various heparin-scavengers, while, it remains a great challenge for gaining the external-stimuli responsive PA-release material. In this study, a generic strategy is developed for fabricating photoresponsive protein materials with the designed azobenzene-containing surfactant. For the first time, based on the isomerization of azobenzene, both cationic and anionic proteins could be phase change biomaterials which are capable of transiting to isotropic state under UV irradiation at room temperature. The formation of isotropic state could set the proteins free from the binding state, activating their intrinsic biological functions. Employing this mechanism, one smart PA material for inhibiting heparin is developed, which could effectively photo-modulate the heparin concentration by turning on-and-off the free state of PA from the binding state. With good biocompatibility, the PA material addresses photoresponsive hemostatic activity in biological studies, confirming its great potential clinical values. This work provides a new designing strategy for gaining photocontrollable hemostasis materials, also opening new opportunities for developing photoresponsive protein drugs and biomedical materials.