Under the deal the two powers have agreed to share military intelligence and increase cooperation in the Asia-Pacific region. Relations between Beijing and both Washington and New Delhi have deteriorated sharply over the past few years.
As a result India, which traditionally avoided regional alliances, has been moving closer to the US.
In June 20 Indian soldiers were killed in a clash with Chinese troops across the two countries contested border.
The deal was agreed by US Secretary of State Mike Pompeo who has been touring the region together with Defence Secretary Mark Esper.
In total the two men will visit four countries in what Mr Pompeo said was a mission focused on the “threats” from China.
India and the US have reached a new security agreement
The two sides met in New Delhi
In response to the deal Mr Pompeo said: “Our leaders and our citizens see with increasing clarity that the CCP is no friend to democracy, the rule of law, transparency, nor to freedom of navigation, the foundation of a free and open and prosperous Indo-Pacific.”
The CCP refers to the Chinese Communist Party which has ruled China as a dictatorship since winning a civil war in 1949.
Subrahmanyam Jaishankar, the Indian foreign minister, described its warming relationship with the United States as “exceptionally positive”.
The agreement was also welcomed by Mr Esper who made clear it is aimed at containing China.
Our leaders and our citizens see with increasing clarity that the CCP is no friend to democracy”
He said: “We stand shoulder to shoulder in support of a free and open Indo-Pacific for all, particularly in light of increasing aggression and destabilizing activities by China.”
However, Beijing reacted angrily to the new accord accusing the US of dividing the region.
Speaking of Mike Pompeo, Wang Wenbin, a spokesman for the Chinese Foreign Ministry, commented: “We urge him to abandon the Cold War and the zero-sum game mentality and stop sowing discord between China and regional countries as well as undermining the regional peace and stability.”
The deal signed on Tuesday had been under negotiation between the US and India for just under a decade.
WW3: China and Russia hint at new MOST POWERFUL military alliance EVER [CONFLICT]
Britain strikes back! UK launched SECRET cyber-attacks on Russia [ANGER]
China ramps up World War 3 fears as new alliance with Russia [INSIGHT]
20 Indian soldiers were killed in a border clash earlier this year
Mike Pompeo visits a memorial to Indian soldiers killed in recent border clashes
However New Delhi had previously been reluctant to sign for fear of antagonising China.
Harsh Pant, director of studies at the New Delhi Observer Research Foundation, said India is looking to build alliances in response to growing Chinese assertiveness.
Speaking to Voice of America he said: “India has been very cautious in the past, but it is now taking a more categorical position.
“Basically, as China challenges India on its borders, New Delhi is now out in the open about aligning its priorities with the US and like-minded countries in the Indo-Pacific.”
Mr Pant insisted the strengthened relationship will endure regardless of who wins next week’s presidential election.
He argued: “No one is questioning why this conversation is happening at this time because India is one area where there is perhaps more consensus between the two US presidential candidates than anywhere else.
“There is bipartisan support in Washington for strengthening ties with India.”
Protests in India after clashes on the Chinese border earlier this year
Mr Pompeo will go on to visit Sri Lanka, the Maldives and Indonesia on his Asian tour.
June’s border clash took place in the Galwan Valley along the disputed Indian-Chinese border.
As well as the Indian fatalities there were reports of Chinese casualties but Beijing has not publicly released the figure.