A device may recognize a tilt gesture when a device rotates about an axis and then back again. The gesture may be recognized using a state machine. Recognition of the gesture may be performed based on a context of a device, where the specific movement of the device during a tilt gesture may change based on the context. The tilt gesture may be confirmed using a classifier trained on features describing the gesture and the context.