Differential flat underactuated robots have fewer actuators than degrees of freedom (DOFs). This characteristic makes it possible to design light and cost-effective robots with great dexterity. The primary challenge associated with these robots lies in effectively controlling the passive joint, in particular, when collisions with obstacles in the workspace have to be avoided. Most of the previous research focused on point-to-point motions without any control on the actual robot trajectory. In this work, a new method is presented to plan trajectories that include one or more via points. In this way, the underactuated robot can avoid the obstacles in the workspace, similarly to traditional fully actuated robots. First, a trajectory planning strategy is analytically described; then, numerical results are presented. The numerical results show the effects of the via points and of the order of the polynomials adopted to define the motion laws. In addition, experimental tests performed on a two-DOF underactuated robot are presented, and their results validate the proposed method.