The markets were trading marginally higher in a relatively choppy session of trade as weakness in the global markets seeped in and profit booking in IT shares also weighed.
The Sensex was up 68 points, at 16,768 and the Nifty was hovering around 5,013, up 12 points.
Earlier in the day, the Nifty touched a high of 5,114 in opening deals and thereafter slipped to a low of 5,006 on profit-taking.
The markets, however, bounced back on fresh buying in RIL, ICICI Bank and State Bank of India. Early noon, the markets received a fresh jolt after the European bourses opened in the negative note.
Meanwhile, Asian markets ended in the red, snapping two sessions of gains.
The Nikkei Stock Average, the Hang Seng and the Shanghai Composite indices closed down over 1% each. European markets also opened lower; FTSE, CAC and DAX slipped between 1-2% each as investors turned cautious ahead of the US nonfarm payrolls data. Analysts expect 53,000 nonfarm jobs in August, following a gain of 117,000 in July.
Back in India, a slew of negative macro indicators also weighed on the markets.
The HSBC Markit, India's Manufacturing PMI fell to 52.6 in August against 53.6 reported in July due to decline in orders
The Inflation for the week ended August 20 surged to 10.05% due to sharp rise in vegetable prices raising concerns that the Reserve Bank of India would continue to tighten further. The RBI has raised rates 11 times since March 2011 to contain high inflation.
A K Prabhakar, Senior Vice President Equity Research from Anand Rathi said, "Indian markets have bucked trend because they were catching up with the global markets, short covering in heavyweight Reliance Industries and banking stocks have helped the markets." Prabhakar added, if Nifty holds above 4,960, than index can easily scale to 5,150.
Reliance Industries, ICICI Bank and ITC were up between 1-3% each and contributed 90 points on the Sensex. However losses in BHEL, TCS and Infosys, were capping the gains.
IT shares were the worst hit on concerns of slowdown in IT spending due to debt concerns in Europe and growth slowing down in the US.
Besides the frontline stocks, HCL Technologies, Tech Mahindra and Core projects were down over 1% each.
High beta metal shares were leading the gains. JSW Steel was the top gainer, up 5%, followed by Sterlite Industries and Bhushan steel, up over 4% each.
Market breadth was positive, 1,522 stocks advanced, for 1,190 shares which declined on the BSE.