Porphyromonas gingivalis has been linked to the development and progression of oesophageal squamous cell carcinoma (ESCC), and is considered to be a high-risk factor for ESCC. Currently, the commonly used methods for P. gingivalis detection are culture or DNA extraction-based, which are either time and labour intensive especially for high-throughput applications. We aimed to establish and evaluate a rapid and sensitive direct quantitative polymerase chain reaction (qPCR) protocol for the detection of P. gingivalis without DNA extraction which is suitable for large-scale epidemiological studies. Paired gingival swab samples from 192 subjects undergoing general medical examinations were analysed using two direct and one extraction-based qPCR assays for P. gingivalis. Tris-EDTA buffer-based direct qPCR (TE-direct qPCR), lysis-based direct qPCR (lysis-direct qPCR) and DNA extraction-based qPCR (kit-qPCR) were used, respectively, in 192, 132 and 60 of these samples for quantification of P. gingivalis. The sensitivity and specificity of TE-direct qPCR was 95.24% and 100% compared with lysis-direct qPCR, which was 100% and 97.30% when compared with kit-qPCR; TE-direct qPCR had an almost perfect agreement with lysis-direct qPCR (κ = 0.954) and kit-qPCR (κ = 0.965). Moreover, the assay time used for TE-direct qPCR was 1.5 h. In conclusion, the TE-direct qPCR assay is a simple and efficient method for the quantification of oral P. gingivalis and showed high sensitivity and specificity compared with routine qPCR.