Some of the most useful scientific discoveries are completely by accident. One perfect chemical example is the discovery of teflon, a non-stick surface coating polymer that is particularly useful with frying pans and baking trays. In the early 20th century, a chemist was trying to make a new type of coolant fluid for use in refrigeration compressors. He made tetrafluoroethylene, a gas that can be stored in canisters. He eventually noticed that the canisters of this gas ran empty long before they should based on the volume of gas the canister was filled with (the percent yield was less than 100%). One day he opened up an empty canister and found the inside was coated with a slippery polymer. The gas had polymerized under high pressure and with the metal of the canister as a catalyst to form a polymer later called teflon.
Other examples of accidental chemical discoveries include the area of artificial sweeteners. While this is not a result of lower yields than expected, none of the original sweetening chemicals like saccharine or aspartame were originally created as sweeteners. Their sweet flavor as discovered by accident.