EARLIER in December Wang Yi, the Chinese foreign minister, said his country “disapproves” of spheres of influence in international affairs. He was speaking in Delhi, India’s capital, a fact that underscored a point China is making increasingly clear by other, less diplomatic means: the thing it really disapproves of is India maintaining a sphere of influence.

Separated from the rest of Asia by the world’s biggest mountains, India is the elephant on its own subcontinent. Leaving aside perennially hostile Pakistan, it has effortlessly dominated smaller neighbours much in the way that America does in the Caribbean: they may grumble and resent their sometimes clumsy big brother, but they have learned to stay out of its way. Lately, however, China’s increasingly bold advances are challenging India’s sway.

Consider the past few weeks. On December 9th Sri Lanka granted a 99-year lease of a strategic port on its southern coast to a company controlled by the Chinese government. The same week an alliance of two communist parties swept parliamentary polls in Nepal; they had campaigned for closer ties with China and more distant ones with India. At the end of November, after a hasty “emergency” session of parliament with no opposition members present, the Maldives became the second South Asian country after Pakistan to ratify a free-trade agreement with China. The low-lying archipelago in the Indian Ocean, which sits beside trade routes along which an estimated 60,000 ships pass every year, has also leased an island to one Chinese firm and awarded big infrastructure projects to others.

India has faced challenges in its traditional sphere before, says Tanvi Madan of the Brookings Institution, an American think-tank. What is different is the scale and speed of China’s incursion. Until 2011, for instance, China did not even have an embassy in the Maldivian capital, Male. But after a state visit to the island republic by Xi Jinping, China’s president, in 2014—the first by a Chinese leader—military, diplomatic and economic ties have strengthened rapidly. China now holds some 75% of the Maldives’ debt, reckons Mohamed Nasheed, an exiled former president.

Atoll costs

Following the Maldives’ sudden free-trade deal with China, India’s foreign ministry could only drily intone, “It is our expectation that as a close and friendly neighbour, [the] Maldives will be sensitive to our concerns, in keeping with its ‘India First’ policy.” Rather than reaffirm its commitment to upholding Indian interests, however, the Maldivian government abruptly suspended three local councillors for the sin of meeting with the Indian ambassador without seeking prior permission. In the past the Maldives, with its 400,000 people, would not have dared snub its neighbour of 1.3bn so blatantly. The affront is all the more glaring given that a muscular foreign policy is one of the electoral planks of India’s prime minister, Narendra Modi, whose party just won a hard-fought election in his home state of Gujarat.

In Nepal, too, the Chinese dragon has advanced swiftly. As long ago as the 1950s its rulers had reached out to China in a bid to counterbalance India, which controlled nearly all access to the landlocked kingdom—as it was then—and was pressing the royal family to allow some democracy. “But all it took to manage Nepal then was a few boxes of whisky,” says Constantino Xavier of the Carnegie Endowment for International Peace, another think-tank.

Decades later, when Nepal’s king again made overtures to China, India mounted an 18-month economic blockade that ultimately persuaded him not only to shun his northern neighbour but also to allow multiparty elections. When Nepalese Maoists, briefly in government in 2008 following a ten-year civil war, went to China seeking aid, they came away empty-handed. “They were told a mountain has two sides; know which one you are on,” says Mr Xavier. In other words, Nepal should recognise Indian dominance.

Nepal, now a republic, issued a new constitution in 2015. India saw it as unfair to lowland regions that lie along its border, and so again showed its muscle. But rather than crumple in the face of a new blockade (which was imposed by Nepalese protesters but tacitly backed by India, which still controls nearly all road access), Nepal’s wobbly government held its ground. To assert its independence it signed several deals with China. In the just-completed elections this policy paid off handsomely for Nepal’s communists, who were able to promise giant Chinese investments in hydropower, roads and the country’s first railway. This will run not downhill from Kathmandu, the Nepalese capital, to India, but over the mountains to China.

Nepal’s ties to India remain extremely strong. Millions of Nepalese work there; it is Nepal’s biggest trading partner; and the two countries’ armies have historically been tightly bound. But whereas India has counted on this legacy to sustain its influence, China has busied itself with funding scholarships, think-tanks and junkets to China for Nepalese journalists and academics. Back in the 1960s, a Nepalese delegation met Mao Zedong, recalls Mr Xavier. “He told them that only in 50 years, when a train reached from Tibet to Kathmandu, could China match India’s influence.”

India has met China’s push with consternation, and the occasional pushback. Quite literally so: over the summer Indian troops crossed onto territory claimed by another small country in India’s orbit, Bhutan, to block a road-building incursion by Chinese forces. The intervention did stop China, but has tested India’s relations with a country that relies heavily on Indian aid and is such a close ally that it has yet to establish diplomatic relations with its only other neighbour, China. This may have been the intention. China has long been quietly offering to resolve its border disputes with Bhutan through an exchange of territory. India has blocked the idea, for fear that it would strengthen China at a point of military vulnerability for India.

In that particular contest India may be a match for China, in determination if not in strength. India’s foreign-policy establishment is well aware of its other weaknesses in relation to its northern neighbour and has worked hard to address them. It used to rely on the sheer immensity and harshness of the Himalayas to act as a barrier, and deliberately built no roads that a Chinese invader might use. That has changed: India is furiously struggling to catch up with China’s burgeoning and impressive border infrastructure.

But retaining an Indian “sphere of influence” remains a tricky task. Aside from the fact that India’s economy is only a fifth of China’s in size, and that its messy democracy makes policymaking slow and cumbersome, India suffers important institutional constraints. Its entire corps of diplomats amounts to just 770 professionals, compared, for example, with America’s 13,500 foreign-service officers. Indian aid to its neighbours has suffered from poor delivery through inefficient public-sector companies. And until recently India has shied away from working with other countries that are equally concerned by China’s expansionism. All of this is changing, however. The Indian elephant may be slow to learn, but it is hard to budge.