Electrical vehicles (EVs) have a main role in the new power systems. Charging/discharging, energy supporting, voltage/power variations, and cost are some main issues relating to the EV‐based networks. The property of energy storage in EVs using charging/discharging pattern can assist the microgrid (MG) in power balance and supporting the load demand specially in on‐peak times. Location and size optimization of charging parks are also effective parameters in improvement of these systems. Optimal location and capacity of EV charging park are the main focus of this article, which is done based on the probability of routing of vehicles and arrival time to the park in different parts of MG identified as residential and commercial parts. Selecting the optimal locations and sizes of charging park can improve the performance of MG in terms of voltage/power profile, energy cost, and energy trading with the main grid, which is discussed in this article. Simulation results show that optimal EV charging parks help the MG to support more load demands in on‐peak times and reserve energy in off‐peak times to balance the energy flow in the network. Using the proposed strategy results in 31.96% reduction in cost function and causes 10.54% reduction in total energy cost of the MG in a year.