In this paper, polystyrene nanofiber were made using electrospinning polystyrene inside THF/DMF solvent. The major parameters such as voltage, distance between injection and collector, polystyrene concentration and rotating speed of collector were optimized in electrospinning technique. The results indicated that in specific range, with increasing voltage, high electrospinning distance, low flow of injection and high collector’s speed, we could achieve to nanofiber having regular chain structure and less diameter. In optimal condition and unmodified surface, polystyrene fiber had average diameter of 82.1 nm. Finally polystyrene absorbent by dithizone were modified and through selecting best condition, the modified polystyrene nanofiber with 92.98 nm average diameter were obtained which although it has more diameter than unmodified nanofiber, it possesses properties which the unmodified nanofiber does not have those properties, for example property of absorbing metals.