You can make dyes for fabrics from simple plant colours. The picture below shows a yellow dye made from onion skins on the left, and a blue dye made from red cabbage on the right. I took two samples of cloth, and left them in the dye baths for two hours. The yellow dyed fabric is on the left, the blue dyed is on the right, with a piece of the undyed fabric in the middle for comparison.
Surprisingly, the fairly weak colour from the onion skins gives a better result than the vivid blue dye of the red cabbage. And the colour stays on the onion-dyed cloth, whereas the colour washes out from the red cabbage cloth.
This is because natural dyes need a second chemical to help them bind to the cloth. This sort of chemical is known as a mordant (the word comes from the Latin word mordere, meaning to bite – the mordant was thought to help the dye bite the cloth). Onion skins contain their own mordant, called tannin, which is why they colour the cloth better.
One common mordant you could try is Alum