In this study, the filtering problem is investigated for both linear and non-linear systems. A new generalised proportional–integral–derivative filter (GPIDF) is proposed by introducing the idea of proportional–integral–derivative (PID) control. It utilises the past, current and future information to estimate the current state in order to achieve a better filtering performance. Besides, the GPIDF provides a unified structure to accommodate a variety of filtering scenarios as its special cases, including the popular generalised Kalman filter. Based on the new proposed GPIDF structure, the optimal PID filter and extended optimal PID filter are designed using the minimum mean square error criterion at each time step. In addition, the practical strong robust proportional–integral filter and extended strong robust proportional–integral filter are developed without requirements of knowledge about model uncertainty. The developed filters are recursive and suitable for real-time online applications. Finally, two simulation studies are carried out to demonstrate the effectiveness and applicability of the authors' proposed methods.