A novel nanocomposite coating made of poly-o-phenylenediamine (PoPD) and oxidized multiwalled carbon nanotubes (MWCNTs) was electrochemically prepared for the first time on stainless steel wire. Subsequently, it was applied to headspace solid-phase microextraction (HS-SPME) and gas chromatographic analysis of biphenyl and seven polycyclic aromatic hydrocarbons (PAHs). The effects of polymerization potential, polymerization time, concentration of o-phenylenediamine and oxidized MWCNTs were investigated on the coating process. The fiber coating was carried out easily and in a reproducible manner, and the produced fiber was stable at high temperatures. The surface morphology of the coating was examined by scanning electron microscopy (SEM). The effects of various parameters on the efficiency of HS-SPME process, such as desorption temperature, desorption time, extraction temperature, extraction time and ionic strength were also studied. Under optimized conditions, the calibration graphs were linear in the range of 0.1–300ngmL−1, and the detection limits for biphenyl and PAHs studied were between 0.02 and 0.09ngmL−1. The intra-day and inter-day relative standard deviations obtained at 5ngmL−1 concentration level (n=5), using a single fiber, were 3.2–7.8% and 5.2–9.3%, respectively. The fiber-to-fiber RSD% (n=3) were 6.2–11.3% at 5ngmL−1. The proposed HS-SPME method was successfully applied for the analysis of PAHs in water samples.