The structural, electronic and optical properties of the GaAs1-x P (x) ternary alloys together with their binary GaP and GaAs compounds were investigated in the zinc-blende (ZB) phase using the density functional theory. The lattice constant of the GaAs compound decreases while its bulk modulus increases when the doping concentration of the P dopant is increased. In addition, both parameters (lattice constant and bulk modulus) show small deviations from the linear concentration dependence. The energy band gap of the GaAs compound is of the direct nature, which increases with the increase in the P dopant concentration, whereas at higher P dopant concentration, the band gap shifts from direct to indirect character. On the other hand, the hydrostatic pressure has a significant effect on the band structure of the investigated compounds where the binary GaAs compound changes from a direct band gap semiconductor to an indirect band gap semiconductor at P a parts per thousand yen 5 GPa. Furthermore, the pressure-dependence of the optical properties of the GaAs, GaP and GaAs0.75P0.25 alloy were also investigated, where the calculated zero frequency refractive index and the dielectric function are also compared with the experimental results as well as with different empirical models.