Chinese President Xi Jinping is expected lay the groundwork with Indian Prime Minister Narendra Modi, pictured on a billboard in Mumbai, India, for a wave of Chinese investment into the country. Getty Images

NEW DELHI—China’s president is expected to pledge billions of dollars in investments for India this week as Beijing looks to gain influence with a regional heavyweight at a time when Asia’s balance of power is in flux.

During a three-day trip to India, Xi Jinping will meet Indian Prime Minister Narendra Modi and lay the groundwork for a wave of Chinese money to build industrial parks and bullet trains in a country hungry for development.

Underlying China’s sharply rising interest in its neighbor is a fear that India could tilt too far toward Beijing’s rivals, namely Japan and the U.S., both of which have been courting India’s new government.

“China doesn’t want to lose India,” said Kanti Prasad Bajpai, a professor of Asian studies at the National University of Singapore. “It sees both an economic opportunity and a geopolitical incentive in engaging India at this point.”

India is wary of China. The two countries fought a 1962 war and their Himalayan border remains in dispute. Last year, New Delhi accused Chinese troops of making a weekslong incursion. Beijing denied its soldiers had crossed into Indian territory.

At the same time, New Delhi needs money to achieve Mr. Modi’s goals of improving the country’s infrastructure, building a manufacturing base and making the world’s second-most-populous country more prosperous.

For now, Mr. Modi seems content to glean what benefits he can from the strategic competition among China, Japan and the U.S. And he is not averse to playing them off against each other to bag sweeter deals for India.

The Indian prime minister has a warm personal relationship with Japanese Prime Minister Shinzo Abe. During a recent visit, the two greeted each other with a bear hug, agreed to increase defense cooperation and vowed to build a “special” strategic partnership to shape the 21st century.

In Tokyo, Mr. Modi took a swipe at Beijing, criticizing what he called an “expansionist mind-set” that leads to “encroaching on another country, intruding in others’ waters.”

Mr. Modi returned from Tokyo with a promise of $35 billion in investment over five years.

Shortly after Mr. Xi leaves, Mr. Modi is scheduled to dine in Washington with President Barack Obama, and discuss deeper defense and energy ties with the U.S.

“China tends to be more amenable…to Indian interests when India moves closer to its rivals,” Shyam Saran, a former diplomat and China specialist, said recently. “Its pressures on India mount when India is seen to have fewer options.”

India has participated in naval exercises with Japan and the U.S. It is also strengthening ties with other Asian countries, including Vietnam, with which it agreed this week to expand cooperation in oil and gas exploration in the contested waters of the South China Sea, defying Chinese warnings.

Mr. Modi has also announced plans to ramp up investments in border infrastructure to improve military logistics. An extensive road network on the Chinese side has given Chinese troops an edge.

In a glimpse of the unresolved challenges the two sides face, Indian authorities said Monday that Chinese civilians and soldiers disrupted construction of a canal in the Himalayan region of Ladakh.

Simrandeep Singh, a senior official there, said around 50 Chinese troops and 120 civilians protested, raising banners that said: “This is Chinese territory.” Mr. Singh said work on the canal has stopped “because we didn’t want tensions to rise.”

Deep-seated political anxiety has torpedoed Chinese investments in India in the past. Indian officials have tended to view such deals with skepticism and see Chinese companies as possible fronts for espionage operations.

Even cheerleaders of Chinese money are quick to emphasize that India must safeguard its national security interests. India could accept Chinese high-speed trains, they say, but not Chinese railroad signaling systems.

“We should draw clear red lines as to where they can come in and where they can’t,” said Jayadeva Ranade, the president of the New Delhi-based Center for China Analysis and Strategy.

India is evolving a two-track China policy by which it opens its doors to Chinese money, stepping closer into its economic orbit, while boosting military preparedness and strategic partnerships to cope with Beijing’s rise.

Indian officials want Chinese companies to set up factories in India to manufacture products for Indian consumers as well as for export to help narrow the country’s $30 billion-plus trade deficit.

China is India’s largest trading partner, with bilateral trade at $66 billion. Most of that value is Chinese exports, including power and telecommunications equipment, to India. India’s main exports to China are raw materials.

India is also keen for Chinese investment, especially in infrastructure. Chinese direct investment in India, which totals about $400 million, trails far behind $16 billion in cumulative investments from Japan.

Mr. Xi is expected to announce an investment of $5 billion in two industrial parks—one in Mr. Modi’s home state of Gujarat and another in the neighboring state of Maharashtra. The two sides may also firm up deals for bullet trains.

“We believe that during this visit, the Chinese and Indian relationship of the last 50 to 60 years will see a directional change,” India’s trade minister Nirmala Sitharaman said last week. “Despite being neighbors, we have not been able to move forward on a number of opportunities.”

At a summit in July of Brics nations—Brazil, Russia, India, China, and South Africa—India signed on to China’s proposal for the group’s new development bank to be headquartered in Shanghai.

India is also likely to join the China-led Asian Infrastructure Investment Bank, which Beijing has proposed as an alternative to the Japan and U.S.-controlled Asian Development Bank, to help meet its multibillion dollar infrastructure-financing needs.

Indian officials say they are working to address concerns about China’s control over the multilateral bank.

Mr. Modi “will go the extra mile on economic issues,” Mr. Bajpai of the National University of Singapore said. “But he will also be more blunt and strong on India’s differences with China.”