Hydrogels based on chitosan derivatives, sodium alginate with acrylamide and acrylic acid were obtained by free radical solution copolymerization method in the presence of ammonium persulfate as initiator and urotropin and N,N methylene bisacrylamide as crosslinking agents. The formation of hydrogels was proved by extraction and IR spectroscopy. It is shown that hydrogels are able to fix the temporary form in iron (III) chloride solutions and reclaim it in solutions of ascorbic acid in less than 2 hours. Hydrogels based on sodium alginate have the best physical-mechanical characteristics compared with chitosan-based - the strength reaches 0.7 MPa and 0.11 MPa, the elasticity modulus is 1.02 MPa and 0.17 MPa at 65% deformation, correspondingly.