This paper proposes the optimal operation of ESS (Energy Storage System) in the substation of urban railway in an economical point of view. Since the load patterns of urban railway have different characteristics with the general power demand pattern, the characteristics motivate us to develop the optimal operation algorithm for ESS under Korean electricity billing system. We also introduce two different ESS operation strategies for peak load shaving and electricity consumption charge minimization respectively, and formulate each scheme. Historical data from Namgwangju substation are used for economical comparison of the strategies. The results show that the proposed algorithm is the most cost-effective ESS operation scheme among the strategies and reduces around 5 percent of electric charges compared to the charge without ESS operation.