In its simplest form, the instrument consists of an air bottle connected to the external atmosphere by a small tube. As the aircraft moves up or down in the atmosphere, the pressure inside the air bottle changes to equalise with the external air pressure. This causes air to move through the tube. The faster the aircraft is ascending (or descending), the faster the air flows. The variometer simply measures and displays the direction and speed of the airflow in the tube. This simple and effective instrument, known as an "uncompensated" variometer, is used in most powered aircraft. The variometer has particular importance, however, for un-powered aircraft.
Human beings, unlike birds, are not able directly to sense climb and sink rates. Before the invention of the variometer, sailplane pilots found it very hard to soar. Although they could readily detect abrupt changes in vertical speed ("in the seat of the pants"), their senses did not allow them to distinguish lift from sink, or strong lift from weak lift. The actual climb/sink rate could not even be guessed at, unless there was some clear fixed visual reference nearby. Being near a fixed reference means being near to a hillside, or to the ground. Except when hill-soaring (exploiting the lift close to the up-wind side of a hill), these are not generally very profitable positions for glider pilots to be in. The most useful forms of lift (thermal and wave lift) are found at higher altitudes and it is very hard for a pilot to detect or exploit them without the use of a variometer. The invention of the variometer (by Max Kronfeld) moved the sport of gliding into a whole new realm.
As the sport developed, however, it was found that these simple "uncompensated" instruments had their limitations. The information that glider pilots really need to enable them to soar is not the vertical speed of the glider itself, but the vertical speed of the air through which it is flying. When the pilot chooses to dive or to pull up, a simple variometer will faithfully indicate a corresponding change in climb or sink rate. This means that you can only use an uncompensated variometer to detect areas of atmospheric lift or sink when in level flight. Pulling up or diving makes the readings effectively meaningless.
The action of diving and/or pulling up a sailplane affects its velocity. You can exchange height for speed or speed for height. In energy terms this means exchanging kinetic energy for potential energy or vice versa. A sailplane pilot is mostly interested in the gain of potential energy provided by air currents, and far less interested in the gain of potential energy provided by the easy exchange between potential and kinetic energies (speed for height). It is the change in the sailplane's total energy (potential + kinetic) which interests the pilot.
For this reason most modern sailplanes are equipped with a type of instrument known as the total energy or compensated variometer, which adjusts its measurement of the change of potential energy by subtracting the change of kinetic energy. This is done using a pitot tube directed towards the front of the sailplane, at the entrance of the variometer. If the pilot causes the sailplane to dive, the increase in air-speed causes a reduction in pressure from the venturi. This compensates for the increase in the external static pressure, the net effect being no change to the reading on the variometer. The effect of changing aircraft velocity is eliminated, and in effect the total energy variometer is an instrument that describes the vertical motion of the air through which the glider is flying.
In modern gliders, electronic variometers generate a sound whose pitch and rhythm depends on the instrument reading. This allows the pilot to concentrate on the external view instead of having to watch the instruments, thus improving safety and also giving the pilot more opportunity to search for promising looking clouds and other signs of atmospheric lift.