Empty containers repositioning between ports has a high cost to shippers and occurs when the quantities of exported and imported cargoes are different in a certain maritime trade area, leaving empty containers at some ports and missing ones in others. To meet customer demand, companies can develop actions that cause losses, for example, pass on their customers to other companies when there is no availability of empty containers. Thus, the realization of studies presenting solutions for empty container repositioning problem is needed, aiming at minimizing the costs involved in this activity. This study proposes an algorithmic solution to the empty container repositioning problem by using approximation methods (metaheuristics), specifically the particle swarm optimization.