Alen Stajcic hails the Matildas in Olympic quarterfinal loss to Brazil

Devastated Matildas coach Alen Stajcic has described his side's Olympics quarterfinal loss to Brazil as one of the most courageous efforts he has seen in Australian sport.

Australia's Rio campaign came to an end on Friday night, snuffed out in a dramatic 7-6 quarterfinal penalty shootout in Belo Horizonte.

Looking to break a 0-0 stalemate after extra time, the Matildas had a chance to seal a semifinal berth when local star Marta missed Brazil's fifth spot kick, only for Katrina Gorry's reply to be saved.

Defender Alanna Kennedy was then left distraught after missing the deciding penalty, unable to put her shot past the outstretched glove of goalkeeper Barbara at a full-house Mineirao.

It came after Australia nearly settled the tense affair minutes from the end of regulation time when Chloe Logarzo rattled the crossbar from distance.

The result was sweet retribution for the host nation, so cruelly ejected by Australia in the round of 16 at last year's Women's World Cup.

For the Matildas, it was a heartbreaking end to a bold bid to bring home their country's first Olympic football medal.

"We're all gutted," Stajcic told AAP. "The players showed an amazing amount of courage, resilience and tenacity.

"We didn't dominate the game technically or tactically.

"Though with all those other attributes, we nullified Brazil to a large extent and created chances of our own.

"That was one of the best efforts I think I've seen from an Australian sporting team.

"Unfortunately, it's courage in the face of defeat.

"Nothing else matters other than the result, and we pulled up just short."

The players echoed their coach's sentiments on social media.

Absolutely shattered to have our Olympic campaign end like that. It's hard to put into words how proud I am to share the field with these warriors, and how lucky I am to have them as sisters. This is just the beginning ���� #neversaydie #proud #family

A photo posted by Stephanie Catley (@stephcatley) on

"Absolutely shattered to have our Olympic campaign end like that," Steph Catley posted on Instagram.

"It's hard to put into words how proud I am to share the field with these warriors, and how lucky I am to have them as sisters.

"This is just the beginning."

Brazil, led by five-time world player of the year Marta, had the share of possession and tested Australia throughout an absorbing 120 minutes.

The hosts had the edge in a frenetic first half rife with turnovers, as Australia held their own but struggled to string quality passes together.

Catley came closest early with a cross that almost swung into the top right corner of goal.

But her involvement was short-lived, the star left-back succumbing to injury and replaced by Logarzo moments later.

It forced midfield linchpin Elise Kellond-Knight to shift to left-back, leaving her teammates to deal with the audacious Formiga, who was quickly becoming a thorn in Australia's defence.

But whenever it was pierced, veteran custodian Lydia Williams stood out including a sweeping dive to deny Debinha and a sensational goal-line save to stop Andressa Alves toeing in minutes from full time.

Brazil upped the onslaught but were let down by final-third profligacy -- and some desperate defending from Kennedy who stuck her foot out to deny Alves a sure thing.

Brazil will face Sweden in a semifinal on Tuesday after the Scandinavians' penalty shootout defeat of the United States.