The anisotropic XY ferromagnet has been studied by Monte Carlo simulation in a three dimensional simple cubic lattice. The increase in critical temperature (ferro-para transition) has been noticed with increasing the strength of anisotropy. The effects of random fields (both with full circular symmetry and in angular window) on the critical temperature are investigated systematically in the anisotropic XY ferromagnet in three dimensions. Reduction of the critical temperature of anisotropic XY ferromagnet has been observed in the presence of random field. The compensating field (the required amount of field which preserves the critical temperature for isotropic XY ferromagnet) has been studied as a function of the strength of anisotropy. The compensating field was found to depend linearly on the strength of anisotropy. We have also studied the effects of random field confined in the angular window and observed the reduction of the critical temperature with increase of the angular extension. The critical behaviours are formalised by the usual finite size analysis and the estimation of critical exponents for the susceptibility and the specific heat.