Dirty water coming back up in the toilet can be caused by a blocked drain, a malfunctioning check valve, or a problem with the sewer line. When the drain is clogged, water cannot flow through it properly, causing the dirty water to back up into the toilet. Alternatively, a damaged or faulty check valve can fail to prevent wastewater from flowing back into the toilet. Sewer line issues might also be responsible for wastewater backing up in the toilet.