It was created, on the foundations of the TREVI cooperation, as the Justice and Home Affairs pillar by the Maastricht Treaty in order to advance cooperation in criminal and justice fields without member states sacrificing a great deal of sovereignty. Decisions were taken by consensus rather than majority and the supranationalinstitutions had little input. The Treaty of Amsterdam transferred the areas of illegal immigration, visas, asylum, and judicial co-operation in civil matters to the integrated European Community. The term Justice and Home Affairs later covers these integrated fields as well as the intergovernmental third pillar. The pillar was renamed "Police and Judicial Co-operation in Criminal Matters" to reflect its reduced scope. Before the Maastricht Treaty, member states cooperated at the intergovernmental level in various sectors relating to free movement and personal security as well as in customs co-operation and judicial policy. With Maastricht, Justice and Home Affairs co-operation aimed at reinforcing actions taken by member states while allowing a more coherent approach of these actions, by offering new tools for coordinating actions. The Treaty of Lisbon, which entered into force in December 2009, abolished the entire pillar system. The PJC areas and those transferred from JHA to the Community were once more grouped together in creating an area of freedom, security and justice.
The Maastricht Treaty established that, while reaching the objectives of the Union, and notably the freedom of movement, the member states consider the following as areas of common interest under Justice and Home Affairs:
Asylum;
Rules concerning the entrance of external borders;
Immigration policies and policies concerning third countries' citizens:
*Conditions of entry and circulation for foreign citizens in the territory of the Union;
*Conditions of residence for foreign citizens in the territory of Member States, comprising families and employment access;
*Fight against irregular immigration, residence and work of foreigners within the territory of the Union;
Fight against international fraud where this is not covered by points 7), 8) and 9);
Judicial co-operation in civil matters;
Judicial co-operation in penal matters;
Customs co-operation;
Police co-operation for preventing and fighting terrorism, drugs trade and other grave forms of international criminality, comprising, if necessary, certain aspects of customs co-operation.