Two mathematical formulations and two efficient heuristic algorithms are proposed. A prototype of the web application is developed to support carpooling at the company. Computational experiments indicate high potential for reductions in CO2 emissions. Potential reductions might be heavily affected by the number of shift typologies.