The effect of ELMS on the vertical position observer in TCV has been investigated and a new, optimized, observer which minimizes the influence of ELMS has been constructed. The new observer has been tested in TCV, under closed loop conditions, and it is shown to be considerably less sensitive to ELMS than the classical observer. In order to determine whether this method could also be used in JET, ELMy H mode discharges and vertical displacement events in JET are analysed and a modified vertical position observer is constructed, optimized for JET conditions. It is shown that, if this new observer had been used in JET, the perturbations caused by ELMS would have been greatly reduced.