The invention discloses a foamed nickel/MXene-Co3O4 composite electrode and a preparation method thereof. The preparation method comprises the following steps of: (1) pretreatment of foamed nickel, namely, taking the foamed nickel, carrying out ultrasonic cleaning with sulfuric acid, ethanol and deionized water in sequence, and performing drying at a constant temperature; and (2) preparation of a composite electrode, namely, mixing MXene and Co3O4 to prepare mixed powder, coating the surface of the foamed nickel with the mixed powder, and performing vacuum plasma sintering to prepare the composite electrode. The foam material composite electrode is prepared through the foamed nickel, the MXene and the Co3O4, the MXene-Co3O4 mixed powder is stably combined through the foamed nickel under the high-temperature and high-pressure effects of a vacuum plasma sintering furnace, use of an adhesive is avoided, the preparation cost is reduced, and the preparation time is only 40-60 min; the organ-shaped structure of MXene can effectively accommodate and disperse a catalyst, the problem that the catalyst is easy to agglomerate is overcome, the activity and stability of the catalyst are improved, and the prepared electrode is large in specific surface area, and good in conductivity, and an electrode material with excellent performance can be formed.