This is a question i see asked alot, its pretty simple too.
This is what my engine bay looked like after:
So how do you do it?
– First block up all holes in the tank
– Now get some small grain rice, in the case of a head tank, pour about a cup full in.
– I found it helped if i put some cleaning agent in, so used a squirt of fairy liquid and added a some water.
– Next put header tank cap on. And shake it. Yep, you read it right, shake it!
– You will have to monouvere the rice into all the separate sections and shake it about but should be easy enough.
– Rinse and repeat if required

Of course you will never make it look completely new but it will get rid of most of the staining and as you can see from my pictures, it makes a difference. I think the correct term is tumbling.
Oh and ps, make sure you get all the rice out!