from one of my favourite books,
Life Stories of Australian Insects by Mabel N. Brewster, Agnes A. Brewster, and Naomi Crouch, Dymock's Book Arcade, Sydney, 1946:
FAMILY PSYCHIDAE (Case Moths) These are moths whose larvae live within silken causes, covered either with pieces of stick or leaves, attached or just more or less smooth. In walking, the caterpillar has only the head and three pairs of horny legs without the case, and this part of the body is consequently hardened, and is much darker in colour than the rest of the body which is protected by the case. It drags the case along as it walks. The method of constructing the case is worth observing. We reared some larvae of the large case moth from the egg. At first they resembled tiny black threads, but when they moved we saw that each had a slender web attached to itself. The spinning commenced at once, till a tiny bag was made. This increased in size, but the larva worked along the upper edge, much as one proceeds in knitting a sock. The growth of the case keeps pace with the growth of the larva. The upper edge is always loose, so that it can be attached to any object. To strengthen the case, pieces of sticks, leaves, pine needles, etc., may be woven in.The occupants of these cases were gone when I found them. They are a faggot case and an Oeceticus elongata.
Everyone has noticed these case moths and the wonderful arrangement of the 'sticks' or leaves. The inside of the case is smooth and silky. If the caterpillar be placed in a box with a glass lid, one will soon see regular transverse lines of short silken threads, not unlike railway sleepers, all over the surface of the glass. These are the 'foot-holds' of the caterpillar to enable it to move over the smooth surface of the glass. It does it so quickly that one can hardly see the placing of these threads. The larva pupates within the case, and then a beautiful, soft, white, silky 'blanket' is made to protect the pupa. The female never leaves the case—she is wingless and lays the eggs within it. The male emerges from the end of the case, the pupal shell being pushed right out, and hangs from the tip of the case. The male moth is winged and is not very conspicuous. The tiny larvae let themselves down from the case by long silken threads.
Oeceticus elongata, the largest case moth, the larva of which forms a very large case, with pieces of stick sewn in, is of orange-brown and black colour. There is the faggot case, leaf case, and the beautiful little ribbed case. The 'moths' are popularly named from the type of case woven by the larvae. Interesting experiments can be made to show the weaving powers of the larvae. We cut the case of the Oeceticus from end to end. Almost instantly the larva drew it together at the upper end; then wove the edges so neatly and so closely that it was hard to detect where the incision had been made. It is curious, too, to find that there are careless individuals who just cobble their cases together; we came across this three or four times. Another time we made a case of flannel in the form of the Oeceticus case. We removed the larva from its own case and left it overnight. In the morning we found it was comfortably within the flannel case. Then we placed its own case back again. It vacated the flannel one and went back to its own case. We split open the flannel case and found it was lined with a layer of silky threads . . . The Oecticus elongata has a very long existence as a caterpillar—a year, and they can live without food supply for months.
It's no wonder that its own case would be far preferred to anything we could construct. As a feltmaker, for years I've made what to our touch, is a very soft fabric from fine Merino wool.
Imagine the silken luxury inside. Even the most pea-under-a-dozen-mattress-sensitive princess is a lout with skin as thin as cork bark compared to the demands of these rather common caterpillars. And every one of these larvae spin and weave finer than the most enchanted princess.