You wash a shirt, it smells fine, and fifteen minutes into your workout the smell is back. Here's why, and what helps.

Bacteria from your skin settle in the fibres of your clothes. Some form biofilms: protected clusters that detergent only partly reaches. Odour molecules stay behind with them.
As soon as you sweat again, those bacteria get back to work. That's why a clean shirt can start to smell within minutes. Researchers call it permastink.
In our research, shirts from 26 people, collected after an hour-long spinning session, were smelled by a trained odour panel. Polyester smelled worse than cotton.
The reason: micrococci, bacteria that turn sweat into odour, grow better on polyester. Much sportswear is made of it.
Washing at 30 °C with a mild detergent removes only part of the bacteria, and adds biofilm-forming bacteria that live in the machine. Those are the hardest to get rid of, and a key cause of the smell that develops in clothes.
In a study of household washing machines, bacteria from skin and clothes ended up on freshly washed cotton, and the rinse water still held up to millions of living bacteria per millilitre.
So the machine can carry odour-causing bacteria from one load to the next.
See the studiesFor regular clothes, not the probiotic T-shirt:

Organic cotton with encapsulated probiotics that are released gradually, wear after wear. Wash it at 30 °C with a regular enzyme-based detergent: 60 °C or higher damages the bacteria.
Order the T-shirtLess odour on your skin means less odour in your clothes.