Understanding when and how the first galaxies formed and what sources reionized the universe are key goals of extragalactic astronomy. Over the last few years great progress has been made by pushing the observational frontier of galaxies out to z~9-12, only ~450 Myr from the Big Bang. Thanks to several large surveys with the Hubble Space Telescope (HST) we have now identified almost 1000 galaxies at z~7-8, in the heart of the cosmic reionization epoch, and we are now building up the sample sizes at z~9-11. These detections allow us to directly track the evolution of the cosmic star-formation rate density over 96% of the age of the universe. Additionally, the combination of ultra-deep HST and Spitzer/IRAC datasets has proven to be extremely powerful leading to the first measurement of the stellar mass density out to z~10. In this talk I will highlight recent progress in exploring the build-up of the first generations of galaxies down to the peak of cosmic star-formation at z~2 based on deep HST and Spitzer surveys, and I will provide a future perspective how this field will be revolutionized in the JWST era and beyond.