The CERN Axion Solar Telescope (CAST) is an axion helioscope searching for axions and axion-like particles produced in the Sun. An introduction to the detection principle and its layout will be presented. Extensive R&D efforts have been carried out for low background detectors which improve the sensitivity of the experiment. In 2013 CAST has extended its sensitivity into the sub-keV energy range to search for solar chameleons, thus becoming also sensitive to dark energy particles. In 2016 CAST started operating as a haloscope as well, looking for axions produced in the early universe. A description of the upgrades will be given, together with the latest results.