This is a moth which lays its eggs in a bumble bee nest, or more rarely in a wasp nest.
There the larvae feed on any organic material, e.g. the wax cells and their con- tent of nectar and pollen in a bumble bee colony, but they may also attack the bee larvae.
When fully grown the moth larvae leave the nest in a body and in a sheltered spot nearby they then spin a communal cocoon, which may contain hundreds of pupae.
These are commonly found, sometimes so firmly attached to the substrate that it is difficult to break them loose.
The larvae may cause damage by gnawing the substrate to provide a suitable site for the communal cocoon, but otherwise they are completely harmless. The adult moths do not attack textiles or anything else in the house.