The invention belongs to the technical field of heat exchangers, and discloses an anti-frost device and a heat exchanger. The anti-frost device comprises fins, a bottom plate and a pipeline assembly, the fins are installed on the bottom plate, an air flow channel is arranged between the fins and the bottom plate, the pipeline assembly comprises a liquid inlet pipe and bottom branch pipes, and the liquid inlet pipe communicates with the bottom branch pipes. The bottom branch pipes are laid at the ends, close to the bottom plate, of the fins, one-way pieces are arranged on the bottom branch pipes, and the flow guide direction of the one-way pieces is from the bottom branch pipes to the liquid inlet pipe. The heat exchanger comprises a box body and the anti-frost device, the anti-frost device is installed on the box body, and the bottom plate is located at the bottom of the box body. The pipeline assembly can conduct a refrigerant, when heating work is executed, the low-pressure and low-temperature refrigerant does not pass through the bottom branch pipes at the ends, close to the bottom plate, of the fins, freezing caused by the too low temperature of the bottom plate is prevented, the air flow channel can increase the air flow, volatilization of accumulated water on the bottom plate is accelerated, and then the heat exchange performance of the heat exchanger is improved.