Toilets will make noise when you flush them, but if your toilet makes excessive noise such as whistling, you can quiet the toilet down by swapping a single part. You don't need to tear into the house's plumbing, and you don't need any special tools to complete the job and quiet the toilet down.
While the sound may make some think the pipes leading to the toilet's water valve are making the whistling and other noises, the actual cause comes from the ball cock, or the valve that fills the toilet's tank with water. When you press the toilet's handle and let the water out of the tank, the float attached to the ball cock falls and opens the ball cock's valve all the way. As the float rises, the ball cock's valve closes more and more. The partway open valve will emit different noises, including whistling.
Old Fill Valves
Older toilets may still have an old ball cock fill valve, which often will make more noise than more modern fill valves. Take your toilet tank's lid off, and set it aside to see what kind of fill valve your toilet has. If you see a black float that is on the end of a metal rod, you have an old cock fill valve. Newer fill valves still use a float, but it travels up and down on a rod next to the fill valve.
Out With the Old
If you want to get rid of the noises in the toilet's tank, you will need to remove the old ball cock before you can install a new fill valve. Twist the handle on the toilet's water valve clockwise as far as you can by hand, and then flush the toilet. Use a sponge and bucket to drain the rest of the water out of the tank. Unbolt the water line from the bottom of the tank since it connects to the bottom of the ball cock. Remove the retaining nut from the bottom of the toilet, which holds the ball cock in place, and lift the ball cock out of the tank.
In With the New
With the old ball cock out of the toilet's tank, you are ready to install the new fill valve. Insert the fill valve into the hole in the bottom of the tank, and tighten the retaining nut in place to secure the valve. You'll then need to bolt the water supply line onto the bottom of the fill valve on the underside of the tank. Open the water valve, and allow the water to start filling the toilet's tank. To adjust the water level in the tank, twist the screw on the float or pinch the clip next to it.