In this paper, we introduce the time window assignment vehicle routing problem (TWAVRP) with time-dependent travel times. It is the problem of assigning time windows to customers before their demand is known and creating vehicle routes adhering to these time windows after demand becomes known. The goal is to assign the time windows in such a way that the expected transportation costs are minimized.We develop a branch-price-And-cut algorithm to solve this problem to optimality. The pricing problem that has to be solved is a newvariant of the shortest path problem, which includes a capacity constraint, time-dependent travel times, time window constraints on both the nodes and on the arcs, and linear node costs. For solving the pricing problem, we develop an exact labeling algorithm and a tabu search heuristic. Furthermore, we present new valid inequalities, which are specifically designed for the TWAVRP with time-dependent travel times. Finally, we present results of numerical experiments to illustrate the performance of the algorithm.