The first stars can be constrained by the chemical composition of distant galaxies. It is crucial to understand how and when the first stars formed to understand the formation and evolution of our Universe. The latest observational data reveal unprecedented information about the chemical enrichment of the early Universe, which seems to behave differently from the local Universe. The first stars, being very massive, enrich their metal-poor environment in an uncertain way. To predict the abundances of the first galaxies, we include nucleosynthesis yields from Population III stars up to 300Msun, including faint supernovae, Wolf Rayet and Pair Instability Supernovae into our state-of-the-art hydrodynamical cosmological simulations. Our code (based on Gadget-3) also includes the latest nucleosynthesis yields from population II stars (from Kobayashi et al. 2020) for all stellar mass ranges. We predict the chemical abundance evolution of galaxies for different elements from the early Universe to the local Universe. For example, we find that the N/O abundance gives a systematically larger value with nucleosynthesis yields from Population III stars, which is comparable with observational data of the GN-z11 galaxy. I also discuss the evolution of metallicity gradients and elemental abundances of the intergalactic medium. We constrain our model by comparing it with observational data from the James Web Space Telescope (JWST) and the Atacama Large Millimeter/submillimeter Array (ALMA).