The flat spectrum radio quasar 3C 279 is known to exhibit pronounced variability in the high-energy (100 MeV < E < 100 GeV) γ-ray band, which is continuously monitored with Fermi-LAT. During two periods of high activity in April 2014 and June 2015 target-of-opportunity observations were undertaken with the High Energy Stereoscopic System (H.E.S.S.) in the very-high-energy (VHE, E > 100 GeV) γ-ray domain. While the observation in 2014 provides an upper limit, the observation in 2015 results in a signal with 8.7σ significance above an energy threshold of 66 GeV. No VHE variability was detected during the 2015 observations. The VHE photon spectrum is soft and described by a power-law index of 4.2 ± 0.3. The H.E.S.S. data along with a detailed and contemporaneous multiwavelength data set provide constraints on the physical parameters of the emission region. The minimum distance of the emission region from the central black hole was estimated using two plausible geometries of the broad-line region and three potential intrinsic spectra. The emission region is confidently placed at r ≳ 1.7 × 1017 cm from the black hole, that is beyond the assumed distance of the broad-line region. Time-dependent leptonic and lepto-hadronic one-zone models were used to describe the evolution of the 2015 flare. Neither model can fully reproduce the observations, despite testing various parameter sets. Furthermore, the H.E.S.S. data were used to derive constraints on Lorentz invariance violation given the large redshift of 3C 279.