Circulating tumor DNA (ctDNA) is a highly promising biomarker for the early diagnosis and treatment of gastric cancer (GC). However, there is still a lack of effective and practical ctDNA detection methods. In this work, a simple and economical capillary non-gel sieving electrophoresis-LED induced fluorescence detection (NGCE-LEDIF) platform coupled with catalytic hairpin assembly (CHA) as the signal amplification strategy is proposed for quantitative detection of PIK3CA E542K and TP53 (two types of ctDNA associated with GC). We have reasonably designed two pairs of programmable oligonucleotide hairpin probes for PIK3CA E542K and TP53. Using a one-pot reaction, the presence of ctDNA triggers the cyclic amplification of CHA, forming numerous thermodynamically stable H1/H2 double-strands. The H1/H2 double-stranded DNA catalyzed by PIK3CA E542K and TP53 can be easily separated by NGCE due to their different lengths, enabling simultaneous detection of both ctDNAs. Under optimal experimental conditions, the detection limits of this strategy for detecting GC-related biomarkers PIK3CA E542K and TP53 are 20.35 pM and 19.61 pM, respectively, and can achieve 730-fold signal amplification. This strategy has a good recovery in the serum matrix. The results of this study show that this strategy has significant advantages such as high selectivity, a simple process, no special instruments and equipment, no need for fluorescence modification of hairpin probes in advance, high automation, low cost, and minimal sample consumption. This provides a powerful method for the detection of trace cancer biomarkers in the serum matrix with good application prospects.