We report herein the fabrication of a novel ternary nanocomposite of mesoporous graphitic carbon nitride/black phosphorus-gold nanoparticles (mpg-CN/BP-Au) and its catalytic performance in the photocatalytic hydrogen evolution reaction (HER) and electrochemical detection of paracetamol. The photocatalytic hydrogen production rate of mpg-CN/BP-Au nanocomposite (1024 µmol g−1 for 8 h) is compared with mpg-CN, mpg-CN/BP and mpg-CN/Au in the presence of triethanolamine (TEOA) as a hole scavenger under the visible light. In addition to the photocatalytic HER application, as-prepared mpg-CN/BP-Au nanocomposite was deposited on modified glassy carbon electrode (mpg-CN/BP-Au/GCE) and for the first time tested for the detection of paracetamol (PA). Under the optimum conditions, linear range of paracetamol detection was found to be in the range of 0.3–120 µM with a detection limit of 0.0425 µM. mpg-CN/BP-Au/GCE provided higher electrocatalytic activity than pristine mpg-CN and all other tested binary nanocomposites. The enhanced photo- and electrochemical activity of mpg-CN/BP-Au/GCE are attributed to formation of heterojunction between BP and mpg-CN materials. Additionally, Au nanoparticles increase the rate of adsorption of mpg-CN/BP due to the excellent electrical properties and spillover effect. We believe that the presented design and catalysis of the ternary nanocomposite will pave a way in many photo- and electrochemical applications.