A technology able to forecast fire dynamics in buildings would lead to a paradigm shift in the response to emergencies, providing the Fire Services with essential information about the ongoing blaze with some lead time (i.e. seconds or minutes ahead of the event). But the state-of-the-art of Computational Fluid Dynamics in fire dynamics is not fast nor accurate enough to provide valid predictions on time. This paper presents a methodology to forecast fire dynamics using Computational Fluid Dynamics based on assimilation of sensor observations. The forecast is posed as an inverse problem to solve for the invariants governing the dynamics, and a tangent linear approach is used in the optimisation. The forward fire model is linearized in order to obtain a quadratic cost function that is easily minimised. A series of real-scale compartment fire cases are investigated using the Computational Fluid Dynamics code FDSv5 together with synthetic data. Up to three different invariant are considered (spread rate, burning rate and soot yield) in scenarios with one or two fires and different origins. The effect of density, location and type of sensors is studied. It is shown that the use of coarse grids in the forward model significantly accelerates the assimilation up to 100 times without loss of forecast accuracy due to the aid of sensor data. This provides close to positive lead times using Computational Fluid Dynamics. These results are a fundamental step towards the development of forecast technologies able to lead the fire emergency response.