The invention discloses an anti-bacterial glaze and a preparation method thereof. The glaze comprises the following raw materials in parts by mass: 40-50 parts of titanium dioxide, 0.5-0.8 part of zinc nitrate, 0.5-0.8 part of cerous nitrate, 3-5 parts of glacial acetic acid, 8-12 parts of distilled water, 30-40 parts of absolute ethyl alcohol, 0.2-0.3 part of a surfactant and 800-1200 parts of granite. The preparation method comprises the following steps: preparing an antibacterial agent, mixing for preparing glaze slip and sintering at a high temperature, so as to obtain the anti-bacterial glaze. According to the ceramic glaze with an anti-bacterial function, provided by the invention, by modifying titanium dioxide and doping titanium dioxide with related metal elements, a visible region of the titanium dioxide is enabled to have an antibacterial property; moreover, the ratio of all components is scientific and reasonable, a glaze surface is smooth, uniform color, good dispersity, high acid resistance and high alkali resistance are realized and the application range is wider.