gnats or fruit flies may have gathered in your bedroom for a few reasons, including: if no forgotten food is lying about, you may have a water issue. check for leaks in a nearby bathroom or along the roof line. houseplants can also host hundreds of tiny gnats.