A liquid device using two immiscible dielectric liquids is prepared. One liquid is black and forms a droplet on a glass substrate. The other liquid is used to fill the surrounding of the droplet. When a fringing field is applied to the device, the droplet is stretched by a dielectric force. The droplet can switch a probing beam. Our results show that the optical switch exhibits a hysteresis. The width of the hysteresis is dependent on the amplitude of the voltage, the frequency, and the viscosity of the surrounded liquid. By controlling the hysteresis, our device has potential applications in light shutters, optical attenuators, and displays.