In time-domain radio astronomy with arrays, voltages from individual antennas are added together with proper delay and fringe correction to form the beam in real time. In order to achieve the correct phased addition of antenna voltages, one has to also correct for the ionospheric and instrumental gains. Conventionally this is done using observations of a calibrator source located near to the target field. This scheme is suboptimal since it does not correct for the variation of the gains with time and position in the sky. Further, since the ionospheric phase variation is typically most rapid at the longest baselines, the most distant antennas are often excluded while forming the beam. We present here a different methodology (“in-field phasing”), in which the gains are obtained in real-time using a model of the intensity distribution in the target field, which overcomes all of these drawbacks. We present observations with the upgraded Giant Metrewave Radio Telescope (uGMRT) which demonstrates that in-field phasing does lead to a significant improvement in sensitivity. We also show, using observations of the millisecond pulsar J1120−3618 that this in turn leads to a significant improvement of measurements of the Dispersion Measure and Time of Arrival. Finally, we present test observations of the GMRT discovered eclipsing black widow pulsar J1544+4937 showing that in-field phasing leads to improvement in the measurement of the cut-off frequency of the eclipse.