A vector is a magnetic heading given to an aircraft by air-traffic control (ATC) to be flown for a period of time or distance. It can be a magnetic compass heading or the numerical value of that heading. For instance, ATC can tell an aircraft to "fly a heading of 270" or "turn right to a heading of W." In both cases, the aircraft would be flying in the same direction, since 270 is the numerical equivalent of West.
Vectors are usually given to aircraft for four main reasons: departures, airspace transitions, approaches, and collision avoidance.
A departure vector may be assigned to an aircraft to fly immediately after takeoff. They can also be assigned to fly upon reaching a specific altitude. ATC might say "after takeoff, fly heading 030," or "upon reaching 500 ft, fly heading 030." Also, before the flight has begun and the aircraft is still taxiing, the ATC clearance control might issue specific instructions that involve a vector to be flown upon reaching a specific altitude, landmark, distance, or time.
Airspace transition vectors: because ATC has to control many aircraft at the same time, it is necessary to vector aircraft. Aside from aircraft taking off and landing at a particular airspace airport, planes just trying to fly through the airspace to their destination also have to be controlled. Due to this, ATC may assign transitioning aircraft a vector to keep them out of their high traffic zones. For example, if a plane was flying from New York City to Miami and was going over Washington, D.C.’s airspace, the ATC facility in charge of that airspace might issue the aircraft a vector to keep it away from the airport or a more important area like the White House.
Approach vectors: aircraft coming in to land at an airport may receive a vector for many reasons. If the aircraft was in instrument conditions, it would make an instrument approach (an approach with reference to instruments) to land at the airport. The pilot has an option to be vectored to the final approach fix (FAF) or to shoot the entire approach. Normally, the vectors are chosen because it saves time and money rather than shooting a long and tiresome approach. Aircraft may also receive vectors to the runway when in VFR (visual flight referencing) conditions to shorten flight time or to lengthen flight time. If the airspace is busy, then ATC might be vectoring aircraft in order to allow for a smooth flow into the airport.
Collision avoidance vectors: in this case, vectors will be given to both or one of the aircraft to avoid an incident or accident. If two aircraft are flying, and they become dangerously close together, then it would be the job of the controlling agency in charge of that airspace to make both aircraft aware of the situation and vector them to safety. If both aircraft were in VFR conditions, then it would be the responsibility of the pilot to avoid an incident or accident, but the controller would most likely call out "traffic" and issue a vector to safety.
Some other cases in which a vector might be issued would be by the ATC facility for practice, if they are requested by the pilot for instruction, if there is an emergency or the pilot in command (PIC) has lost use of his instruments necessary to fly and land safely. In all these cases, ATC would issue vectors for the pilot to fly either by having the pilot use his instruments or magnetic compass or, what is less common, by issuing a no gyro approach in which the controller tells the pilot when and in what direction to start the turn and when to stop turning.