Sperm competition is a potent postcopulatory selective force where sperm from rival males compete to fertilize a limited set of ova. Considering that sperm production is costly, we expect males to strategically allocate sperm in accordance with the level of competition. Accordingly, previous work has examined a male's strategic allocation in terms of sperm number. However, the seminal fluid proteins (Sfps) transferred along with sperm may also play a crucial role in competition. Surprisingly, the strategic allocation of Sfps has remained largely unexplored. Using Drosophila melanogaster, we examined the expression of three seminal fluid and four spermatogenesis genes in response to perceived sperm competition intensity by manipulating male density in a pre-mating and courtship environment. In the pre-mating environment, we found that males modified Sfp ratios by reducing the production of two spfs when potential rivals were present, while one Sfp and all spermatogenesis genes remained unaltered. In the courtship environment, males did not modify spermatogenesis or Sfp production in response to either rival males or female presence. Our data suggest that perceived competition in the pre-mating environment places a significant influence on Sfp allocation, which may be a general trend in promiscuous animal systems with internal fertilization.