The new α‐keto‐stabilized phosphorus ylide Ph3PCHC(O)PhCN (Y) was synthesized by addition of triphenylphosphine to 2‐bromo‐4′‐cyanoacetophenone, followed by treatment with NaOH 10%. Reaction of ligand (Y) with methanolic solution of mercury(II) halides under mild conditions yielded the binuclear complexes [Y·HgX2]2 [X=Cl (1), Br (2), I (3)]. The new organic/inorganic composite polymer [Hg(NO3)2(Y)]n (4) was synthesized by the reaction of mercury(II) nitrate with the phosphorus ylide Y. Compounds synthesized were characterized by Fourier‐transform infrared, 1H, 31P, and 13C nuclear magnetic resonance spectroscopic methods, which confirmed the coordination of ylide to the metal center through the ylidic carbon atom. Single‐crystal X‐ray structures of phosphorus ylide Y and polymeric complex 4 were also determined and the crystallographic data of complex 4 showed that the title complex has an infinite one‐dimensional structure. Furthermore, the electronic and molecular structures of complexes 1–3 were investigated at the BP86/def2‐SVP level of theory, indicating an increasing trend for C→M bond lengths: Hg2I2 > Hg2Br2 > Hg2Cl2 in [Y→HgX2]2 (X = Cl, Br, I) complexes. In addition, the antibacterial activity of ligand Y and all complexes using the agar disc diffusion method was examined against both selected gram‐positive and gram‐negative bacteria. Results indicated that the ligand Y and complexes 1 and 4 show good antibacterial effect against gram‐positive bacteria tested; besides, the inhibition zones of complexes were significantly larger than those of chloramphenicol as standard.