PCR involves the extraction of DNA from a sample, which is then amplified using thermal cycling. Specific primers bind to the DNA sequences of interest, and the enzyme DNA polymerase extends these primers to form new DNA strands. This process is repeated in cycles, exponentially increasing the amount of target DNA. The amplified DNA can then be quantified and analyzed for the presence of specific pathogens.