Herein, a Barium tungstate (BaWO4) and Graphitic carbon nitride (GCN) based a new electrochemical sensor (BaWO4/GCN/GCE), for the detection of diphenylamine (DPA). Nearly oval-shaped BaWO4 was anchored on the GCN sheets by a worthwhile and simple hydrothermal route. Cyclic voltammetry (CV) and Differential pulse voltammetry (DPV) were used to scrutinize the electrochemical performance of DPA on BaWO4/GCN/GCE. The prepared sensor exhibited phenomenal electrocatalytic action towards the detection of DPA. Moreover, the BaWO4/GCN sensor exhibiting good sensitivity of 1.51267 μA μM −1 cm −2 with the low detection limit (LOD) of 1 nM and a broader linear range from 0.001 to 533 µM for DPA detection under the improved experimental conditions. Furthermore, the effect of storage duration on the BaWO4/GCN sensor's CV response reveals the improved stability. Owing to these extraordinary analytical advantages, the as-produced sensor was applied to analyse the DPA level in apple juice with satisfactory results.