Functional 2-photon microscopy is a key technology for imaging neuronal activity. The recorded image sequences, however, can contain non-rigid movement artifacts which requires high-accuracy movement correction. Variational optical flow (OF) estimation is a group of methods for motion analysis with established performance in many computer vision areas. However, it has yet to be adapted to the statistics of 2-photon neuroimaging data. In this work, we present the motion compensation method Flow-Registration that outperforms previous alignment tools and allows to align and reconstruct even low signal-to-noise ratio 2-photon imaging data and is able to compensate high-divergence displacements during local drug injections. The method is based on statistics of such data and integrates previous advances in variational OF estimation. Our method is available as an easy-to-use ImageJ / FIJI plugin as well as a MATLAB toolbox with modular, object oriented file IO, native multichannel support and compatibility with existing 2-photon imaging suites.