  Context. Phased Array Feeds (PAFs) are multi element receivers in the focal
plane of a telescope that make it possible to form simultaneously multiple
beams on the sky by combining the complex gains of the individual antenna
elements. Recently the Westerbork Synthesis Radio Telescope (WSRT) was upgraded
with PAF receivers and carried out several observing programs including two
imaging surveys and a time domain survey. The Apertif imaging surveys use a
configuration, where 40 partially overlapping compound beams (CBs) are
simultaneously formed on the sky and arranged in an approximately rectangular
shape. Aims. This manuscript aims to characterise the response of the 40
Apertif CBs to create frequency-resolved, I, XX and YY polarization empirical
beam shapes. The measured CB maps can be used for image deconvolution, primary
beam correction and mosaicing of Apertif imaging data. Methods. We use drift
scan measurements to measure the response of each of the 40 CBs of Apertif. We
derive beam maps for all individual beams in I, XX and YY polarisation in 10 or
18 frequency bins over the same bandwidth as the Apertif imaging surveys. We
sample the main lobe of the beams and the side lobes up to a radius of 0.6
degrees from the beam centres. In addition, we derive beam maps for each
individual WSRT dish as well. Results. We present the frequency and time
dependence of the beam shapes and sizes. We compare the compound beam shapes
derived with the drift scan method to beam shapes derived with an independent
method using a Gaussian Process Regression comparison between the Apertif
continuum images and the NRAO VLA Sky Survey (NVSS) catalogue. We find a good
agreement between the beam shapes derived with the two independent methods.
