The invention provides a water-based metal rust inhibitor and a preparation method thereof. The rust inhibitor comprises sorbitan monooleate, inositol hexaphosphate, zinc dihydrogen phosphate, acrylamide, glutamic acid, dinonyl-naphthalenesulfonate, dicyclohexylamine, octadecylamine oleyl sarcosinate, oxidized barium petrotate, sodium ethylenediamine teramethylene phosphonate, 1-hydroxyethylidene, dimethylaminoethyl acrylate, sulfomethylated polyacrylamide, a film forming agent and deionized water. The preparation method comprises the steps of firstly, mixing sorbitan monooleate, inositol hexaphosphate, zinc dihydrogen phosphate and water, and adding octadecylamine oleyl sarcosinate; then, adding acrylamide, glutamic acid, dinonyl-naphthalenesulfonate, dicyclohexylamine and oxidized barium petrotate into the deionized water, and adding 1-hydroxyethylidene; and mixing a mixture I and a mixture II, and adding the left components to obtain the water-based metal rust inhibitor. The rust inhibitor can be attached to the surface of metal, so that the metal has better wear resistance and corrosion resistance.