BACKGROUND: An emerging imaging tool, the functional lumen imaging probe (Endoflip; Crospon Ltd, Galway, Ireland), provides a real-time measurement of esophagogastric junction (EGJ) capacity and diameter, which would be of particular interest in functional esophageal surgery such as Heller myotomy and antireflux procedures. This study aimed to demonstrate the intraoperative use of endoflip in the treatment of achalasia and gastroesophageal reflux disease (GERD). METHODS: In the first case, Heller myotomy was performed under endopflip guidance, for persistent dysphagia after failed endoscopic dilatation. In the second case, the endoflip was used to calibrate a Nissen fundoplication. With the patient under general anesthesia, the endoflip catheter was inserted orally and positioned to straddle the EGJ. At each stage of the procedure, the balloon was inflated by liquid filling at 40-30 ml/min. Live diameter data, cross-sectional area (CSA), and balloon pressure were displayed on the system at all times. RESULTS: Before the myotomy, the pressure in the balloon rose to 15 mm Hg at a CSA of 25 mm(2), indicating that the EGJ is rigid and tight. After the myotomy, the pressure rose to 8 mm Hg, and the CSA opened to 34 mm(2), indicating that the EGJ was now very compliant and flaccid. After the Dor fundoplication, the junction became less compliant, but it could open at its narrowest point to 35 mm(2) at a pressure of 20 mm Hg, suggesting that the EGJ was tighter but not as rigid as before. The second part of the video demonstrates that the Endoflip acted as a "smart bougie," evaluating the orientation and position of a properly constructed floppy Nissen. CONCLUSIONS: The endoflip provides a system in which physiology and anatomy are represented dynamically in the same image. This "smart bougie" could be integrated into the surgical routine to improve outcome and to facilitate surgical training and the learning curve in esophageal functional surgery.