We have measured temperature and magnetic field dependences of the thermal conductivity along the c-axis, kc, and that along the [110] direction, k110, of CuB2O4 single crystals in zero field and magnetic fields along the c-axis and along the [110] direction. It has been found that the thermal conductivity is nearly isotropic and very large in zero field and that the thermal conductivity due to phonons is dominant in CuB2O4. The temperature and field dependences of kc and k110 have markedly changed at phase boundaries in the magnetic phase diagram, which has been understood to be due to the change of the mean free path of phonons caused by the change of the phonon-spin scattering rate at the phase boundaries. It has been concluded that thermal conductivity measurements are very effective for detecting magnetic phase boundaries.