There is an area in the pipe where some air is trapped or the pipe is exposed. The momentum of the water moving through the pipes continues to move the water forward after the valve is shut. This momentum can compress a pocket of air making a sound or it can cause a column of water to rise in a nearby pipe, which will make a clunk when it falls back to its normal level.
Depending where the noise was coming from, but this question is most likely to be answered in this way. If you switched a valve off and the noise was coming before the valve in the pipes, that would indicate a burst pipe.
This is most likely to be water hammer. The most likely reason is because a pipe has not been held down properly with a pipe clamp. It normally happens when a toilet is filling up or when taps are switched off suddenly. Its due to the water pressure in the pipes that makes the water rebound in the pipes causing them to rattle and make a noise
Water pipes can vibrate when the water is turned off due to a phenomenon called water hammer. This occurs when the flow of water is suddenly stopped, causing a pressure surge that can create vibrations in the pipes.
choir members in your pipes
No
Pipes rattle when water is turned off due to a phenomenon called water hammer. This happens when the sudden stop of water flow creates a pressure surge that causes the pipes to vibrate and make noise.
It shouldn't ...
Pipes make a knocking sound when the water is turned off due to a phenomenon called water hammer. This happens when the flow of water is suddenly stopped, causing a pressure wave to travel through the pipes and create the knocking noise.
If pipes are frozen no water can flow, so water meter shouldn't be registering anything. But if pipes are frozen it's a good idea to turn the water off at the inlet. That way you have a chance to discover and leaks and damages when the pipes thaw w/o getting the whole place flooded.
You may have U-Joint problems
U joint
I believe it is due to the pressure build up within the pipes once the water is turned off. I know they sell a product that you place in one of your pipes that serves as a buffer to stop the rattling.