The All Ordinaries index closed up five points at 5,534, a gain of 0.01 per cent. The ASX-200 index added three points to 5,543.
The market began in subdued fashion in the wake of overnight losses on Wall Street and elsewhere.
But the mining sector was able to post solid gains, stopping the market from sliding on the back of losses elsewhere.
Rio Tinto rose 0.7 per cent and shares in rival BHP Billiton ended the session 0.75 per cent higher.
Fortescue Metals Group gained 0.9 per cent and Atlas Iron 1.8 per cent. But Mount Gibson Iron fell nearly 1.5 per cent.
Gold miner Newcrest also ended in the red, falling 0.25 per cent after news of a class action over a major write-down by the company last year, which sent its share price plunging.
Newcrest says it intends to vigorously defend itself.
Finance stocks finished the day slightly down, despite a gain of 0.01 per cent for Westpac. The Commonwealth Bank fell by 0.01 per cent, while NAB lost 0.2 per cent.
The Bank of Queensland gave up 0.7 per cent.
A lunchtime speech by Reserve Bank Governor Glen Stevens had little impact on the market or the Australian dollar.
Mr Stevens told the lunch in Sydney it is still difficult to say when the global economy will fully recover from the global financial crisis.
He also said business confidence could be hurt if a workable solution is not found to the current federal budget impasse, but made no mention of the value of the Australian dollar.
Near the close of trade, the Australian dollar was buying 93.9 US cents, 69.5 Euro cents, 55 British pence, 95.3 Japanese yen and 108.2 New Zealand cents.
West Texas intermediate crude oil was trading at US$105.24 a barrel, while Tapis crude oil in Singapore was selling for US$109.41.
The spot gold price was US$1,306.80 an ounce.