Pebbles drifting past a disk-embedded low-mass planet develop asymmetries in their distribution and exert a substantial gravitational torque on the planet, thus modifying its migration rate. Our aim is to assess how the distribution of pebbles and the resulting torque change in the presence of pebble accretion, focusing on its 2D regime. First, we performed 2D high-resolution multi-fluid simulations with Fargo3D but found that they are impractical for resolving pebble accretion due to the smoothing of the planetary gravitational potential. To remove the smoothing and directly trace pebbles accreted by the planet, we developed a new code Deneb which evolves an ensemble of pebbles, represented by Lagrangian superparticles, in a steady-state gaseous background. For small and moderate Stokes numbers, $ St pebble accretion creates two underdense regions with a front-rear asymmetry with respect to the planet. The underdensity trailing the planet is more extended. The resulting excess of pebble mass in front of the planet then makes the pebble torque positive and capable of outperforming the negative gas torque. Pebble accretion thus enables outward migration (previously thought to occur mainly for $ St in a larger portion of the parameter space. It occurs for the planet mass pl oplus $ and for all the Stokes numbers considered in our study, $ St $, assuming a pebble-to-gas mass ratio of $Z=0.01$. If some of the observed planets underwent outward pebble-driven migration during their accretion, the formation sites of their progenitor embryos could have differed greatly from the usual predictions of planet formation models. To enable an update of the respective models, we provide a scaling law for the pebble torque that can be readily incorporated in N-body simulations.