The Insect EditCochineal comes from the dried bodies of Dactylopius coccus, a type of scale insect which feeds on prickly pear cactus. Scale insects are immobile insects which are often permanently attached to their host plant. They are native to subtropical areas, but are often cultivated in Peru, Mexico, and Australia.
Cochineal was harvested and used by the Aztecs. Europeans discovered it in the sixteenth century and began to export the insects. The dye source was heavily exploited until a synthetic red was developed nearly three centuries later. However, synthetic red dyes often leached harmful chemicals, like arsenic, and cochineal continued to remain an important source of red color.
How to Harvest Edit
The insects brushed off the plant and then submerged in hot water, exposed to sunlight, or baked in an oven to kill them. It takes roughly 70,000 insects to create a 1lb of dyestuff. Because of the harvest method and the amount required, cochineal is relatively expensive by weight.  Cochineal can often be purchased from dye supply houses or imported, in whole or powdered form.
How to Extract Color EditCochineal creates a range of colors, from pale pinks and a variety of reds all the way to deep purples and fuchsias. Grinding the cochineal into a fine powder will all for the greatest color extraction. Trudy Van Stralen recommends "Don't stop when it's gritty like sand or sugar; keep grinding until it's as fine as flour." 
Cochineal is very sensitive to pH. A pH of 4.5 leads to oranges, 4.5-6.5 produces red tones, and neutral pH leads to purples.  Adding cream of tartar to the dye solution will help increase the color yield. A tin mordant or amendment will help retain a bright scarlet red. An ammonia dip after dyeing will help create stable purples. Iron will also create purples. Mixing cochineal with marigolds or fustic will produce oranges.  Historically, lime juice was used to create an acidic solution, thus enhancing the brought reds.  Cochineal is also not lightfast, and will fade over time when exposed.