Persona non grata

In diplomacy, a (Latin: "person not welcome", plural: "") is a status sometimes applied by a host country to foreign diplomats to remove their protection by diplomatic immunity from arrest and other normal kinds of prosecution.
Diplomacy.
Under Article 9 of the Vienna Convention on Diplomatic Relations, a receiving state may "at any time and without having to explain its decision" declare any member of a diplomatic staff "". A person so declared is considered unacceptable and is usually recalled to his or her home nation. If not recalled, the receiving state "may refuse to recognize the person concerned as a member of the mission".
A person can be declared a "persona non grata" before that person even enters the country.
With the protection of mission staff from prosecution for violating civil and criminal laws, depending on rank, under Articles 41 and 42 of the Vienna Convention, they are bound to respect national laws and regulations. Breaches of these articles can lead to a "" declaration being used to punish erring staff. It is also used to expel diplomats suspected of espionage, described as "activities incompatible with diplomatic status", or any overt criminal act such as drug trafficking. The declaration may also be a symbolic indication of displeasure.
So-called "tit for tat" exchanges have occurred (whereby countries involved in a dispute each expel the ambassador of the other country), notably during the Cold War. A notable occurrence outside of the Cold War was an exchange between the United States and Ecuador in 2011: the Ecuadorian government expelled the United States ambassador, as a result of diplomatic cables leaking (WikiLeaks); the United States responded by expelling the Ecuadorian ambassador.
Other usage.
People other than diplomats can be declared "" by a country.
In non-diplomatic usage, referring to someone as "" is to say that the person is not popular or accepted by others.
In the Philippines, local legislatures of provinces, towns, and cities can declare certain people or groups, including non-diplomats and Filipino citizens, as "persona non grata" to express a negative sentiment toward the certain person through a non-binding resolution. This could be in response to the person breaking local ordinance or laws.