I have a plastic container that milk went off in. It is part of a coffee machine. Any hints how to get rid of the smell would be greatly appreciated
Fill up half the container with boiling water and close with lid. So that, vapor can't go out. Wait till it the water cool down completely. Do this with couple of times.
Still you feel the smell, half-feel with water close it with lid and keep that container at your rooftop where it can have direct sunlight throughout the day. Keep it there for at least a week.
Bleach is a miracle chemical for removing smells. Of course you should first wash it with dish soap as suggested in the other answers, but if the smell remains, soak it in water with just a bit of bleach added--a tablespoon per gallon of water should be enough if you soak it for a while. An aggressive bleach solution is one part bleach to nine parts water, but something much weaker is sufficient to remove smells.
If there is any metal involved, you cannot use any but the mildest bleach solution. The chlorine in bleach causes metal to rust, sometimes even forming compounds that will encourage future rust and can't be washed off.
Vinegar has a high level of acidity, which helps to break down and neutralize odor-causing molecules in the air. It can also absorb odors through its porous structure.