The answer to 'why is my P-trap overflowing' is that a clogged or blocked P-trap is the most common cause. The P-trap is the U-shaped pipe under your sink that holds water to prevent sewer gases from entering your home. If this trap becomes clogged with debris, hair, or other obstructions, it can cause the water to back up and overflow.
Other potential causes include a blockage further down the drain line, a broken or damaged P-trap, or issues with the plumbing vent system. Symptoms may include slow draining sinks, gurgling sounds, or foul odors coming from the drain.