InGaP/GaAs heterojunction bipolar transistors (HBTs) with intrinsically or extrinsically carbon doped base layers were grown by metal-organic chemical vapor deposition. Burn-in effect and the influence of thermal annealing at different temperatures on these devices were investigated. Results show that the intrinsically-carbon-doped HBTs demonstrate a higher current gain of 155 and a burn-in value of 24.0%, while the extrinsically-carbon-doped HBTs show a current gain of 92 and a burn-in value of 5.3%. Thermal annealing after exposing the base layer decreases the burn-in value from 24.0% to 5.7% and from 5.3% to 1.3% for intrinsically and extrinsically carbon doped HBTs, respectively, proved to be an effective method to eliminate the burn-in effect of HBT devices by hydrogen out diffusion. However, it also damages the base layer quality, leading to increased base recombination current and decreased current gain.