Oil refineries are big places, which do the complex chemical engineering required to convert crude oil into the various oil products. As we said above, crude oil contains a huge variety of chemicals. What petroleum scientists found in the 1800's is that using distillation techniques, heating the crude oil making it into a vapor then extracting different layers of the vapor, that different valuable products could be extracted.
A huge huge variety of products are now made this way. [Wikipedia1]
For example -- all the asphalt roads we drive on? A lot (but not all) of that is made from the Asphaltene's in crude oil. [Wikipedia2]
However the primary products from crude oil is are fuels like gasoline, diesel and jet fuel.
Another factoid to note is that oil refinery operators make sure to put every ounce of crude oil to some use or another. It means that every ounce of the toxicity leaving the oil well does get distributed somewhere in the ecosphere. While we get alarmed at oil spills and the release of toxic chemicals all concentrated in one place, the truth is that every day all day long we're collectively releasing the same chemicals into the ecosphere. In the form of all the oil products we consume every day all day long.
Some of the chemicals derived from crude oil at refineries are directly used in the refining process, such as hydrogen used for hydrocracking and hydrodesulfurization, or petroleum coke that's burned to provide heat at some refineries.
Our friends at ExxonMobil put this outline of the refining process into a presentation. [ExxonMobil]
Okay, yes, the processes involved require big chemical factories, and produce a dizzying array of useful products that have made our modern society possible. What about the environmental impact at the refinery? [Wikipedia2]