"You should also try to find the source of the flies. Sometimes it's fruit, but it can also be house plants. They like to nest in the wet soil. If I find fruit flies around, I stop watering my house plants for about two weeks and let them get dry. Seems to help."
Well, I want to untangle these things a bit.
There are a few different kind of flies.
There are these little flies that go to fruits and to sour things like vinegar. Fruit flies, drosophila. Some call them vinegar flies.
These traps, as described above, help. Also keep your house very clean for a period of time:
All food, especially fruits, that are eaten, but not only, immediately to the trash. All other fruits (etc.) into areas unreachable by fruit flies.
At the same time, don't produce a feeding ground for fungus.
Get out the trash every day or make it totally inaccessible to the flies.
- Well, as for feeding the parrots with fruits, hopefully the other user's tips help.
There are these little flies around your plants. Fungus gnats AKA sciarids.
The may come, if the plant is a bit overwatered. They don't like your food. You may consider watering the plants from below for a time.
There are flies in the bathroom. Drain flies, "psychodidae", also very tiny. It helps to pour hot water in the sink every day for a time.
I don't know what they eat. But they don't belong there, I guess. They look like mini moths.