Since its independence in 1947, India has maintained cordial relations with most nations. In the 1950s, it strongly supported decolonisation in Africa and Asia and played a lead role in the Non-Aligned Movement. In the late 1980s, the Indian military twice intervened abroad at the invitation of neighbouring countries: a peace-keeping operation in Sri Lanka between 1987 and 1990; and an armed intervention to prevent a coup d'état attempt in Maldives. India has tense relations with neighbouring Pakistan; the two nations have gone to war four times: in 1947, 1965, 1971, and 1999. Three of these wars were fought over the disputed territory of Kashmir, while the fourth, the 1971 war, followed from India's support for the independence of Bangladesh. After waging the 1962 Sino-Indian War and the 1965 war with Pakistan, India pursued close military and economic ties with the Soviet Union; by the late 1960s, the Soviet Union was its largest arms supplier.
Aside from ongoing strategic relations with Russia, India has wide-ranging defence relations with Israel and France. In recent years, it has played key roles in the South Asian Association for Regional Cooperation and the World Trade Organisation. The nation has provided 100,000 military and police personnel to serve in 35 UN peacekeeping operations across four continents. It is an active participant in various multilateral forums, most notably the East Asia Summit and the G8+5. In the economic sphere, India has close relationships with the developing nations of South America, Asia, and Africa. It pursues a "Look East" policy that seeks strengthened partnerships with the ASEAN nations, Japan, and South Korea revolving around many issues, but especially those involving economic investment and regional security.
China's nuclear test of 1964, as well as its repeated threats to intervene in support of Pakistan in the 1965 war, convinced India to develop nuclear weapons. India conducted its first nuclear weapons test in 1974 and carried out further underground testing in 1998. Despite criticism and military sanctions, India has signed neither the Comprehensive Nuclear-Test-Ban Treaty (CTBT) nor the Nuclear Non-Proliferation Treaty, considering both to be flawed and discriminatory. India maintains a "no first use" nuclear policy and is developing a nuclear triad capability as a part of its "minimum credible deterrence" doctrine. It is also developing a ballistic missile defence shield and, in collaboration with Russia, a fifth-generation fighter jet. Other major indigenous military development projects include Vikrant-class aircraft carriers and Arihant-class nuclear submarines.
Since the end of the Cold War, India has increased its economic, strategic, and military cooperation with the United States and the European Union. In 2008, a civilian nuclear agreement was signed between India and the United States. Although India possessed nuclear weapons at the time and was not party to the Nuclear Non-Proliferation Treaty (NPT), it received waivers from the International Atomic Energy Agency and the Nuclear Suppliers Group (NSG), ending earlier restrictions on India's nuclear technology and commerce. As a consequence, India has become the world's sixth de facto nuclear weapons state. Following the NSG waiver, India was also able to sign civilian nuclear energy cooperation agreements with other nations, including Russia, France, the United Kingdom, and Canada.
The President of India is the supreme commander of the nation's armed forces. With 1.6 million active troops, the Indian military is the world's third-largest. It comprises the Army, the Navy, the Air Force, and auxiliary forces such as the Paramilitary Forces, the Coast Guard, and the Strategic Forces Command. The official Indian defence budget for 2011 was US$36.03 billion, or 1.83% of GDP. According to a 2008 SIPRI report, India's annual military expenditure in terms of purchasing power stood at US$72.7 billion, In 2011, the annual defence budget increased by 11.6%, although this does not include funds that reach the military through other branches of government. As of 2012, India is the world's largest arms importer; in the period from 2006 to 2010, it accounted for 9% of money spent on international arms purchases. Much of the military expenditure was focused on defence against Pakistan and countering growing Chinese influence in the Indian Ocean.