Libyan nationality law is regulated by the Constitution of Libya, as amended; the Libyan Nationality Law, and its revisions; and various international agreements to which the country is a signatory. These laws determine who is, or is eligible to be, a national of Libya. The legal means to acquire nationality, formal legal membership in a nation, differ from the domestic relationship of rights and obligations between a national and the nation, known as citizenship. Nationality describes the relationship of an individual to the state under international law, whereas citizenship is the domestic relationship of an individual and the nation. Libyan nationality is typically obtained under the principle of jus soli, i.e. by birth in Libya, or jus sanguinis, born to parents with Libyan nationality. It can be granted to persons with an affiliation to the country, or to a permanent resident who has lived in the country for a given period of time through naturalization.

Acquisition of nationality Nationality can be acquired in Libya at birth or later in life through naturalization.

By birth Those who acquire nationality at birth include:

Children born anywhere whose father is Libyan; however, if born abroad, the birth must be registered with the proper authorities; Children born anywhere, who are illegitimate or whose father has unknown nationality or is stateless and whose mother is Libyan, or whose father is foreign and whose mother is Libyan, following an administrative process and at the discretion of the state; or Abandoned children or orphans discovered in the territory whose parents are unknown.

By naturalization Naturalization can be granted to persons who have resided in the territory for a sufficient period of time to confirm they understand the customs and traditions of the society. General provisions are that applicants have good character and conduct; have no criminal convictions; have good mental and physical health without disabilities; can economically be self-sufficient; lawfully entered the country and are under age fifty. Applicants must have resided in the country for ten years. Adoptions are not allowed in Libya, and there are no provisions for adoptees to acquire nationality in the statutes. Minor children are unable to acquire naturalization when their father naturalizes. Besides foreigners meeting the criteria, other persons who may be naturalized include:

The wife of a Libyan national after two years of marriage; or Persons who have provided significant service to the nation without meeting other requirements.

Loss of nationality Libyan nationals of origin cannot renounce their nationality. Nationals of origin may be denaturalized in Libya for residing outside of the country for more than two years or for acquiring dual nationality without obtaining government authorization, or for minor children if their parent is denaturalized. Naturalized persons may lose their nationality by performing actions against state interests; committing serious crimes, disloyal acts, or crimes against the state or state security; for residing abroad without permission of the state; or for fraud, misrepresentation, or concealment in a naturalization petition.

Dual nationality Limited Dual nationality has been allowed in Libya with permission of the state since 1954.

History From ancient times, Libya was populated by Berber, Garamantian, Haratin, Tebu, and Tuareg peoples who resided in remote areas outside the influences of Cyrenaica, Fezzan, or Tripolitania. The Greeks invaded Cyrenaica in 632 BCE, followed by the Roman invasion of Tripolitania in 146 BCE. Arabs began conquering all three historic regions, Cyrenaica, Fezzan, and Tripolitania from 644 CE. Chieftains dominated the region and individuals were tied to them by kinship networks and religion. Cyrenaica was claimed by the Mamluk Sultanate of Egypt, but little control from the sultan was exerted in the region. Tripolitania was ruled by a succession of leaders of the Maghribi dynasty and Fezzan was governed by the theocratic kingdom of the Beni Khattab dynasty. In 1510, Spanish forces captured Tripoli and sacked the city. Three years later, they turned its defense over to the Knights of St. John of Malta, who in turn were ousted by Sinan Pasha in 1551 placing the area under the rule of the Ottoman Empire.

Ottoman period (1551–1911) After Ottoman Tripolitania was established in 1551, the Ottomans expanded their control in the region bringing the Fezzan leaders under their allegiance in the 1580s. Though authority was not extended to Cyrenaica, the Ottomans established a government agent from Tripoli in Benghazi in the seventeenth century. Within the Ottoman Empire, for six centuries, there was an internal organization that defined government functions for subjects by balancing religious and communal ties, weighing aptitudes and occupations without a centralized national ideology. Ottoman subjecthood was strongly tied to religion and non-Muslims, if they were ahl al-Kitāb (People of the Book), meaning Jewish, Christian, or Zoroastrian, could benefit from being subjects by agreeing to pay a tax to the sultan. Under a pact known as zimma, in exchange for paying taxes, the sultan allowed these subjects freedom of religion and guaranteed their lives, property, and rights with an understanding that they were legally entitled to less status than Muslim subjects. The pact was agreed to by the leaders of the confessional community, who managed the adherents and their internal organization under the religious law of their community.

By the eighteenth century a political organization, known as the millet, managed the affairs of their respective religious communities and developed into the protégé system (, protected persons). Signing treaties with European powers, from the 1673 signing of a Capitulation with France, the Ottoman Empire granted France control of certain Ottoman Christians, Austria control of some Ottoman Roman Catholics, most favoured nation status to British and Dutch traders, as well as specific rights to the Republic of Venice and Russian Empire. Under the terms of these treaties, foreign powers could recruit Ottoman subjects to serve their needs as commercial agents, consuls, or interpreters, and extend to these protégés diplomatic immunity from prosecution and privileges of trade, including lowered customs tariffs. Over time, abuses of the system led to a virtual monopoly of foreign trade by protégés, clandestine sales of letters patent (), and demands from foreign powers for protection to extend from individuals to entire communities. The influence on Ottoman subjects by European powers changed the perception of these minority groups in the empire, meaning that they were increasingly seen not as Ottoman subjects, but as resident aliens. In 1798, France and Britain's conflicts during the Napoleonic Wars extended into Egypt. France occupied the territory until 1801, when the French were defeated and Britain set about assisting the Ottoman Empire in regaining its sovereignty.

To curb the disruptive effects of Europeans in the empire, from 1806, the Ottoman government began sending communiques to the foreign embassies demanding compliance with the terms of their agreements. Ottoman control was re-established in Libya by 1835 and they implemented policies to control the authority of tribal chiefs in the territory. Failing to achieve success diplomatically, in 1839, the Ottoman government issued the Edict of Gülhane, in an effort to end bribery and corruption, and to create fair tax schemes and institutions to protect the basic rights of Ottoman subjects. The Ottoman Reform Edict of 1856 () categorized subjects by whether they were Muslim or non-Muslim, granting different civil statuses to each. In 1863, new regulations upon protégés restricted the privileges they received in the empire and clarifying who were thereafter considered to be Ottoman subjects and who were foreigners.

To further define subjects of the Ottoman Empire, new nationality legislation was passed in 1869 (tâbiiyet-i osmaniye kanunnamesi, Ottoman Nationality Law). The law specified terms for the acquisition and loss of who was within the sovereignty of the empire, rather than the domestic obligations and rights of citizenship. It described who was a subject, owing allegiance, and made provisions for wives, children, emigrants and immigrants. Under its terms, children derived nationality from their fathers, foreigners born in the territory could acquire nationality at majority, and foreigners born elsewhere could obtain nationality after five years residency within the imperial realm. In 1869, the Empire issued two memoranda to foreign consuls and provincial governors to explain that the law would follow custom regarding the age of majority in each region and clarified that the authority for denaturalization belonged to the central authority. It reiterated that the law was crafted with existing treaties in mind, and was therefore not retroactive legislation which might impact European agreements or Ottoman sovereignty.

The 1869 Nationality Law remained in place until 1909. Under its terms children acquired Ottoman nationality from their father, unless they were illegitimate and then derived it from their mother. If an Ottoman wife was married, her children obtained nationality through their father. Foreigners residing in Ottoman territory were considered to be subjects of the Empire, regardless of where they might have originated. Specific provisions included that foundlings discovered within the territory; stateless persons living in the empire; Muslim women, who despite the ban on such marriages, had married Persian men and the children of such a union; unregistered persons who had not been counted in the Ottoman census, either because no census was taken or their births were unregistered, were all considered to be Ottoman. Foreign women acquired Ottoman nationality through marriage, but could return to their original nationality upon the death of their spouse. Nationality could also be granted based on special contribution or service to the nation. Dual nationality was permitted, but was discouraged, as the government could choose not to recognize naturalization of an Ottoman subject by another state.

Since the unification of Italy in 1870, there was an Italian drive to acquire colonial possessions. Having been unable to secure a protectorate in Tunisia, which was annexed by France in 1881, Italians focused on purchasing the Assab Bay in Eritrea in 1882. They extended a protectorate over a portion of Somalia in 1889 and attempted to extend their rule into Ethiopia in 1896, but were defeated. In 1908, when the Young Turks rebelled against the authoritarian rule of the Ottoman sultan Abdulhamid II, a period of instability followed and the Italians took advantage of the disorder in the Empire. Seeing control of Libya as a chance to dominate the sea route between Gibraltar and the Suez Canal, the Italian army was mobilized to invade Libya on 19 September 1911. By 8 July 1912, Italy controlled all of the major Libyan ports that had been under Ottoman control and peace talks began in Lausanne, Switzerland four days later. On 18 October, under the terms of the Treaty of Lausanne, Italy was ceded Cyrenaica and Tripolitania and required to return the Turkish islands of Dodecanese. Knowing the Ottoman Empire was too weak to contest their actions, Italy annexed all three areas.

Italian Libya (1911–1942)