The purpose of a P-trap in a kitchen sink is twofold: to create a water seal and to prevent sewer gases from entering the kitchen. Here's an explanation of each purpose: Water Seal: The P-trap is a U-shaped pipe located beneath the sink basin. One of its key functions is to create a water seal. When water flows down the sink drain, it collects in the bottom of the P-trap, filling up the U-shaped bend. This standing water acts as a barrier, effectively sealing off the pipe and preventing sewer gases from travelling back up into the kitchen. Gas Prevention: Sewer gases, which include unpleasant odours and potentially harmful gases such as methane, can rise up through the plumbing system if not properly contained. The water seal created by the P-trap acts as a barrier, blocking the gases from entering the kitchen through the sink drain. This helps maintain a safe and hygienic environment in the kitchen by preventing the foul odours and potential health hazards associated with sewer gases.