BENGALURU, Jan 17 (Reuters) - Indian shares extended gains on Tuesday, lifted by consumer stocks after data showed domestic inflation was easing and oil refiners rose on the government's cut on a windfall tax on crude oil.

The Nifty 50 index was up 0.68% at 18,017.15 as of 10:38 a.m. IST, while the S&P BSE Sensex rose 0.74% to 60,540.43.

"The Nifty is in a range of 17,800 - 18,200 as even with positive domestic cues like inflation slowing and corporate results so far being good, the market is bothered by continuous selling by foreign investors," Neeraj Dewan, director at Quantum Securities.

Domestic valuations are not cheap after India outperformed major global benchmarks last year, and with China re-opening its borders, funds are getting reallocated to those markets where valuations are relatively attractive, analysts said.

The blue-chip Nifty 50 index rose 4.33% in 2022, while the MSCI's gauge of stocks across the globe slumped 19.8%.

Meanwhile, foreign institutional investors extended their selling streak for the seventeenth day in a row - the longest run in six months - offloading 7.51 billion rupees ($92.00 million) worth of equities on a net basis on Monday.

In domestic trading, fast-moving consumer goods stocks advanced 1.3% and were the best performers among other sectors on hopes that pressure on their margins would ease after data showed India's retail and wholesale prices in December moderated.

Heavyweight Hindustan Unilever rose as much as 3% and was among the top gainers on the Nifty 50.

Oil and gas stocks were up as much as 0.53% after the country, a major consumer and importer of oil, cut a windfall tax on crude oil and exports of aviation turbine fuel and diesel.

Shares of Reliance Industries, Oil India Ltd Chennai Petroleum Corp and Mangalore Refinery And Petrochemicals climbed between 0.7% and 4.4%.

Siemens Ltd rose 3.7% after it said it won a 260 billion rupees order from the Ministry of Railways.

($1 = 81.7760 Indian rupees) (Reporting by Rama Venkat and Bharath Rajeswaran in Bengaluru; Editing by Dhanya Ann Thoppil and Nivedita Bhattacharjee)