The most informative version of this problem is the one where the taps run clear and only the toilet is discolored, because it rules out the supply entirely and points at two places instead: the cistern, where water stands for hours against whatever is in there, and the pan, where it stands for longer still.
Look inside the cistern first
Lift the lid. A cistern that has never been cleaned accumulates sediment on the bottom and biofilm on the walls, and both discolor the water sitting in it. Older mechanisms with steel float arms, steel screws or a corroding fill valve rust steadily into that standing water, and the rust is exactly the color people describe. If the inside of the cistern is stained and the supply into it runs clear, you have your answer without going any further.
Then look at the pan
Brown staining at the waterline that returns within days of cleaning is deposit building up from what the water carries, usually iron or manganese, and it accumulates in the toilet more than elsewhere because the water stands still. In an infrequently used toilet, standing water grows bacterial films that can appear as a brownish or pinkish ring. Neither is a supply problem in the sense of needing treatment, though persistent iron deposits do point at iron in the water.
Ruling the supply back in
Run the cold tap into a clear glass before concluding. Water that arrives clear and turns brown in the bowl over hours is dissolved iron oxidizing in contact with air, which is a supply problem and affects everything, just less visibly. Water discolored at the tap too, across the house, usually follows main works or hydrant use on a mains supply and clears within hours of running the taps. Both need a different response from a cistern clean.
Fixing it
Clean the cistern thoroughly and replace corroding steel parts with plastic equivalents, which are cheap and stop the recurrence. Descale and clean the pan. For iron in the supply, the treatment is oxidation and filtration, and Penn State Extension notes iron and manganese carry secondary aesthetic standards with recommended maximums of 0.3 mg/L iron and 0.05 mg/L manganese, and that oxidized iron fouls softener resin, so iron treatment goes ahead of any softener. Our softener guide covers the order.
Questions people ask about why is my toilet water brown
Only the toilet is brown, where do I look?
Inside the cistern first, for sediment, biofilm or corroding steel float arms and fill valve parts, then the pan itself.
The bowl water browns over hours, what is that?
Dissolved iron oxidizing in contact with air. That is a supply problem affecting everything, just most visibly in the toilet.
What if every tap is discolored too?
On a mains supply that usually follows main works or hydrant use and clears within hours of running the taps.
How do I stop the cistern rusting again?
Replace corroding steel float arms and screws with plastic equivalents and clean the cistern thoroughly.