A handheld device (700) for mixing a liquid and a gas to form foam before a treatment procedure comprises: an inlet for letting a liquid enter the device (700), the inlet adapted for attachment to a syringe containing the liquid, an outlet for letting a formed foam exit the device, a chamber (706) containing a gas, the chamber comprising the inlet and outlet, at least one agitation element (702) disposed in the chamber (706), the at least one agitation element (702) is arranged for independent movement in at least one degree of freedom, the at least one agitation element (702) sized and shaped to mechanically agitate liquid flowing past the at least one agitation element, the liquid flowing in an overall inlet-to-outlet direction, the agitation being sufficient for the at least some of the liquid to mix with the gas to produce the formed foam; the device (700) is dimensioned for holding in one hand.