This is a simplified overview of how a septic system works.
All water runs out of your house from one main drainage pipe into a septic tank.
The septic tank is a buried, water-tight container usually made of concrete, fiberglass or polyethylene. Its job is to hold the wastewater long enough to allow solids to settle down to the bottom (forming sludge), while the oil and grease floats to the top (as scum). Compartments and a T-shaped outlet prevent the sludge and scum from leaving the tank and traveling into the drainfield area.
The liquid wastewater then exits the tank into the drainfield. If the drainfield is overloaded with too much liquid, it will flood, causing sewage to flow to the ground surface or create backups in toilets and sinks.
Finally, the wastewater percolates into the soil, naturally removing harmful bacteria, viruses, and nutrients.