I backwash until the discharge water is clear. Instead of using the sight glass on the sand filter I catch some of the waste water in a white plastic pitcher during the process. It's easier for me to see whether it's clean that way. Then I rinse for at least 30 seconds. If I have enough water in the pool, like right now after some heavy rains, I do the backwash/rinse cycle twice. My experience has been that rinsing for a good 30 seconds and longer, if you have enough water in the pool, is critical.

Be sure you turn the pump off before you change the setting of the multiport valve handle.

If you get dirty water or sand blowing back into the pool you may not be rinsing long enough to pack the sand back down. Or you may have a bad spider gasket (easy to replace).