SN 1987A provides a unique opportunity to study the evolution of a supernova from explosion into very late phases. Owing to the rich chemical structure, the multitude of physical processes involved and extensive radiative transfer effects, detailed modeling is needed to interpret the emission from this and other supernovae. In this paper, we analyze the late-time (about eight years) Hubble Space Telescope spectrum of the SN 1987A ejecta, where 44Ti is the dominant power source. Based on an explosion model for a 19M☉ progenitor, we compute a model spectrum by calculating the degradation of positrons and gamma-rays from the radioactive decays, solving the equations governing temperature, ionization balance and NLTE level populations, and treating the radiative transfer with a Monte Carlo technique. We obtain a UV/optical/NIR model spectrum that reproduces most of the lines in the observed spectrum with good accuracy. We find non-local radiative transfer in atomic lines to be an important process also at this late stage of the supernova, with ∼30% of the emerging flux in the optical and NIR coming from scattering/fluorescence. We investigate the question of where the positrons deposit their energy, and favor the scenario where they are locally trapped in the Fe/He clumps by a magnetic field. Energy deposition into these largely neutral Fe/He clumps makes Fe I lines prominent in the emerging spectrum. With the best available estimates for the dust extinction, we determine the amount of 44Ti produced in the explosion to be 1.5–0.5+0.5x10–4M☉.