Deportation is the expulsion of a person or group of people from a place or country. Today the expulsion of foreign nationals is usually called deportation, whereas the expulsion of nationals is called banishment, exile, or penal transportation. Deportation is an ancient practice, for example: Khosrau I, Sassanid King of Persia, deported 292,000 citizens, slaves, and conquered people to the new city of Ctesiphon in 542 C.E.
Individual or mass forcible transfers, as well as deportations of protected persons from occupied territory to the territory of the Occupying Power or to that of any other country, occupied or not, are prohibited, regardless of their motive. ... The Occupying Power shall not deport or transfer parts of its own civilian population into the territory it occupies.
All countries reserve the right to deport foreigners, even those who are longtime residents. In general, foreigners who have committed serious crimes, entered the country illegally, overstayed and/or broken the conditions of their visa, or otherwise lost their legal status to remain in the country may be administratively removed or deported.
In many cases, deportation is done by the government's executive apparatus, and as such is often subject to a simpler legal process (or none), with reduced or no right to trial, legal representation or appeal due to the subject's lack of citizenship. For example, in the 1930s, during the Great Depression, more stringent enforcement of immigration laws were ordered by the executive branch of the U.S. government, which led to the expulsion of up to 2 million Mexican nationals from the United States. In 1954, the executive branch of the U.S. government implemented Operation Wetback, a program created in response to public hysteria about immigration and immigrants from Mexico. Operation Wetback led to the deportation of nearly 1.3 million Mexicans from the United States.
Already in natural law of the 18th century, philosophers agreed that expulsion of a nation from the territory which it historically inhabits is not allowable. In the late 20th century, the United Nations drafted a code related to crimes against humanity; Article 18 of the Draft Code of Crimes Against the Peace and Security of Mankind declares "large scale" arbitrary or forcible deportation to be a crime against humanity.
Deportation often requires a specific process that must be validated by a court or senior government official. It should not be confused with administrative removal, which is the process of a country denying entry to an individual at a port of entry and expelling them.
Deportation can also happen within a state, when (for example) an individual or a group of people is forcibly resettled to a different part of the country. If ethnic groups are affected by this, it may also be referred to as population transfer. The rationale is often that these groups might assist the enemy in war or insurrection. For example, the American state of Georgia deported 400 female mill workers during the Civil War on the suspicion they were Northern sympathizers.
During World War II, Joseph Stalin (see Population transfer in the Soviet Union) ordered the deportation of Volga Germans, Chechens, Crimean Tatars, Ukrainians and others to areas away from the front, including central and western Soviet Union. Some historians have estimated the number of deaths from the deportation to be as high as 1 in 3 among some populations. On February 26, 2004 the European Parliament characterized deportations of the Chechens as an act of genocide.
The Soviet Union also used deportation, as well as instituting the Russian language as the only working language and other such tactics, to achieve Russification of its occupied territories (such as the Baltic nations and Bessarabia). In this way, it removed the historical ethnic populations and repopulated the areas with Russian nationals. The deported people were sent to remote, scarcely populated areas or to GULAG labour camps. It has been estimated that, in their entirety, internal forced migrations affected some 6 million people. Of these, some 1 to 1.5 million perished.
After World War II approximately 50,000 Hungarians were deported from South Slovakia by Czechoslovak authorities to the Czech borderlands in order to alter the ethnic composition of the region. Between 110,000 and 120,000 Japanese and Japanese Americans on the West Coast, as well as about 3,000 Italian American and about 11,500 German American families, were forcibly resettled from the coasts to internment camps in interior areas of the United States of America by President Franklin Roosevelt.
In the late 19th and early 20th century, deportation of union members and labor leaders was not uncommon in the United States during strikes or labor disputes. For an example, see the Bisbee Deportation.
Deporting individuals to a colony is a special case that is neither completely internal nor external. Such deportation has occurred in history. For example, Britain deported religious objectors and criminals to America in large numbers before 1776, and transported criminals to Australia between 1787 and 1855.
Deportation in the Holocaust
Nazi policies openly deported homosexuals, Jews, Poles, and Romani from their native places of residence to Nazi concentration camps or extermination camps set up at a considerable distance from their original residences. This was the policy known as the "Final Solution". The historical term "deportation", occurring frequently instead of the religious term Holocaust in various locations, thus means in effect "sent to their deaths" — as distinct from deportations in other times and places. 
Expulsion and the legality of collective expulsion
Expulsion is an act by a public authority to remove a person or persons against his or her will from the territory of that state. A successful expulsion of a person by a country is called a deportation.
According to the European Court of Human Rights, collective expulsion is any measure compelling non-nationals, as a group, to leave a country, except where such a measure is taken on the basis of a reasonable and objective examination of the particular case of each individual non-national of the group. Mass expulsion may also occur when members of an ethnic group are sent out of a state regardless of nationality. Collective expulsion, or expulsion en masse, is prohibited by several instruments of international law.