Distribution of the goods from a producer to a customer is one of the most important tasks of transportation. This paper focuses on the usage of genetic algorithms (GA) for optimizing problems in transportation, namely vehicle routing problem (VRP). VRP falls in the field of NP-hard problems, which cannot be solved in polynomial time. The problem was solved using genetic algorithm with two types of crossover, both including and leaving-out elitism, setting variable parameters of crossover and mutation probability, as well as prevention of creating invalid individuals. The algorithm was programmed in Matlab, tested on real world problem of spare parts distribution for garages, while the results were compared with another heuristic method (Clarke-Wright method). Genetic algorithm provided a better solution than the heuristic Clarke-Wright method.