any rotten fruits or rotten milks and gabage back with such kind of stuff. If it came from gabage can, wash the can and spray some anti-bactiria stuff. Also youmay have to wash the place where the flys like to be gathering since the flys lay a lot of eggs everywhere. It's very annoying little thing.