Flapping motion of airfoils in a biplane configuration are optimized for maximizing the thrust and propulsive efficiency. Unsteady flowfields over airfoils flapping in a combined plunge and pitch are computed with a parallel viscous flow solver on moving and deforming overset grids. The amplitudes of the sinusoidal pitch and plunge motions and the phase shift between them are optimized at a fixed flapping frequency and average distance between two airfoils. A gradient based optimization algorithm is implemented in a parallel computing environment. The deforming overset grids remove the restrictions on the flapping motion, and improve the optimization results obtained earlier. At low flapping frequencies, an airfoil in a biplane configuration produces more thrust than a single airfoil. Yet, at high frequencies the airfoil in biplane configuration produced less thrust at a significantly lower efficiency than the single airfoil.