Supercritical CO2 extraction is possibly the cleanest and most efficient way to get cannabinoids, terpenes, and other medicinal compounds from raw plant material. Although the price of the equipment can be expensive to start, the extract products from CO2 extraction are raw, very versitile and medically sterile.
There is not just one method for CO2 extraction. I liken CO2 extraction to a chef with an egg. Depending on the preperation, coooking time, heat, etc. the chef can make an omlette, fried egg, or a souffle. Similarly, CO2 equipment and processess can be changed to focus the extraction of particular compounds to arrive at the desired end products. CO2 extractions are ideal for edibles, concentrates, vapor pens, topicals, gel caps, patches, and almost any other infused product desired. CO2 extracts can come out terpene (flavor) rich or removed for optimal combination into infused products. And the final CO2 extracted products have NO RESIDUAL SOLVENTS, because the CO2 at atmospheric pressure leaves entirely as a gas. And as I mentioned, the final product is MEDICALLY STERILE because the high pressures kill all molds and pathogens that exist naturally on the growing plants.
Most people making cannabis extractions for vapor pens and concentrates are post processing with alcohol or other solvent in a process called "winterization" to remove most of the waxes from the extract, but this is not necessary with the right equipment and process.
Extraction with solvents such as Butane or Hexane have been problematic because it is almost impossible to remove all of the solvent from the final product, and only medical grade solvents have been purified to remove other impurities like pentane, than end up in the final product. Also many folks have blown themselves and their labs up by using these volatile and dangerous solvents. CO2 is non-flammable (it actually is used to put out fires!) and is not toxic if inhaled. It does build up if not vented properly which can cause asphyxiation, but this is highly unusual, and unheard of with proper ventillation. Although CO2 is a greehouse gas, the CO2 can be recycled back into the extraction machine, or vented to a greehouse, where the plants breathe it in for respiration. All operators are urged to develop carbon neutral extraction operations.