The biology of the Milichiidae is rather diverse. Larvae are generally saprophagous and live in decaying plants, but several are coprophagous or even necrophagous.
A very interesting specialization in Milichiidae is myrmecophily. Larvae of Phyllomyza for example have been reared from nests of Lasius fuliginosus and Formica rufa ants, where they live in the chambers and galleries at the bottom of the nest (Donisthorpe 1927). Pholeomyia larvae live in the nests of leaf-cutting ants ( Atta texana), where they feed on the detritus of the fungus gardens (Sabrosky 1959, Moser & Neff 1971, Waller 1980). Other Pholeomyia and Eusiphona species have been reared from the nests of leaf-cutting bees ( Megachile spp.) (Sabrosky 1955, 1982; Teson & Dagobert 1979; De Santis 1981).
Adults often feed on the nectar of small white or yellow flowers, for example Heracleum sphondylium, Ochradenus baccatus, and Solidago canadensis. They can be important pollinators for some plants, like Ceropegia trap flowers (Ollerton 2009). Some species feed on the honeydew of aphids or other Homoptera [ Desmometopa (Herzig 1938), Milichia (de Meijere 1909, Deeming & Báez 1985), Milichiella (J. C. Deeming, pers. comm.)] or are fed by ants: the adults of Milichia dectes, M. proectes, and M. prosaetes are known to solicit regurgitated food from Crematogaster ants (Collin 1921, Farquharson 1921). For photos and observations on this behaviour in Milichia patrizii check out The Ant-Mugging Flies of Kwazulu-Natal.
Another very interesting feature of Milichiidae behavior is kleptoparasitism or commensalism. Species of several genera suck at the prey of spiders or predatory insects such as Reduviidae, Asilidae, Mantidae, or Odonata. Mostly they are attracted to predators feeding on stink bugs (Pentatomidae) or squash bugs (Coreidae) (Frost 1913, Robinson & Robinson 1977, Sivinski & Stowe 1980, Landau & Gaylor 1987). In almost all cases it is only the females that are kleptoparasitic. In some cases a close association between milichiid and predator has been postulated, because it was observed that the fly "rides" on the predator for some time, staying with the one predator rather than changing between different predators (Biró 1899, Robinson & Robinson 1977).