US ambassador's death marks sad day: Carr

The death of the US Ambassador to Libya marks a very sad day and diplomats need to be protected from attack, Foreign Minister Bob Carr says.

The death of the US ambassador to Libya heralds a sad day for his nation, Libya and the diplomatic corps, Foreign Minister Bob Carr says.

Ambassador Chris Stevens was killed when he went to the consulate in Benghazi to try to evacuate staff as the building came under attack by a mob armed with guns and rocket propelled grenades on Wednesday.

Three of his staff, all Americans were also killed.

US Secretary of State Hillary Clinton confirmed the deaths.

Senator Carr said it was a "very sad day" and he would pass on his condolences to Ms Clinton, her colleagues and US Ambassador to Australia, Jeffrey Bleich.

"There's a very important principle in this, that is that diplomats and people in UN missions should be protected and should be immune from this sort of attack," he told Sky News.

"They represent an attempt by nations to engage with one another, to settle differences peacefully, to minimise difference, to get agreement where there is discord.

"They are unarmed, they are easy targets but the international system is based on the work they do."

The minister said Mr Stevens was very helpful when Australia was seeking to secure the release of International Criminal Court and Australian national Melinda Taylor, detained in Libya earlier this year.

"When we were trying to exert all the pressure to get Melinda Taylor out, to get her freed, Chris Stevens was one of the people on the ground in Libya who made representations on our behalf and for her," he said.

"So it makes it all the sadder for us as Australians."

Senator Carr said the death was a sad day for Libya after elections had been won by moderates earlier this year.

"For Libya engaged in this transition to democracy to be faced with this violence and this deadly attack is sad for that country and I feel for the brave Libyan leaders who are steering their countries away from Gaddafi's dictatorship," he said.