We developed an OPCPA preamplifier with an actively shaped output spectrum to obtain a sub-20-fs-duration pulse for a 4-PW laser. The active spectral shaping was facilitated by controlling the temporal profile of a pump pulse in the OPCPA preamplifier. By optimizing the output spectrum of the OPCPA to compensate for the gain-depletion effect in the 4-PW laser, a final laser pulse with a broad spectrum of 101-nm in width (FWHM), resulting in a short pulse duration of 17 fs, was achieved. (C) 2018 Optical Society of America under the terms of the OSA Open Access Publishing Agreemen