In this work, we sought to understand the structural, electronic, optical, and thermodynamic properties of the compound YFe4P12 using the full-potential and linear augmented plane-wave method (FP-LAPW) based on density functional theory (DFT), our calculation of the lattice parameter of this compound YFe4P12 is reasonably in good agreement with the experimental results. Calculations carried out on the electronic band structure showed that the YFe4P12 compound is classified as a direct-gap Half- half-metallic in the minority spins. Moreover, optical properties, such as the optical absorption coefficient, real and imaginary parts of the dielectric function, optical conductivity, refractive index, and optical reflectivity have been studied. The effects of pressure and temperature on the lattice parameter, heat capacities, coefficients of thermal expansion, entropy, and Debye temperature were explored using the quasi-harmonic Debye model.