With the diversification of logistics service development and the intensification of competition, the railway needs to implement differentiation strategy to improve its competitiveness. The optimization in the process of traffic organization is an important link to ensure the differentiation. Under the restriction of different service levels, this paper proposes the optimization model of the design and organization of differentiated transportation products of railway, with the object function of minimum total operation cost. Taking the number of optional route for each traffic flow into consideration, this study gets the optional route set for all the flows at first, and then selects a suitable route for each traffic flow. According to the characteristics of the model, this paper designs a kind of two-stage heuristic algorithm to solve it. Finally, this paper devises a numerical example to test and verify the model and algorithm. The results shows that the optimization ideas and methods proposed have a certain referential significance to the railway transportation organization. © 2011 by Science Press.