The government said the United Nations High Commissioner for Human Rights violated the "basic norms" that should have been observed by an international civil servant when she criticised the Sri Lankan administration.
"The High Commissioner's observation that Sri Lanka is showing signs of 'heading in an increasingly authoritarian direction' is a political statement on her part, which clearly transgresses her mandate," a government statement said.
Pillay on Saturday ended a fact-finding mission to probe allegations of war crimes, four years after the end of a Tamil separatist war that according to UN estimates claimed up to 100,000 lives between 1972 and 2009.
A no-holds-barred military offensive in 2009 crushed Tamil Tiger rebels who at the height of their power controlled one-third of Sri Lanka's territory.
At the end of her mission, Pillay accused Sri Lanka of becoming increasingly authoritarian, with activists facing growing military harassment, the rule of law eroded, and the independence of the judiciary undermined.
"The judgement on the leadership of the country is better left for the people of Sri Lanka to decide, than being caricatured by external entities influenced by vested interests," the government statement said.
Pillay told reporters she had wanted to place flowers and pay respects to all victims of the war at a site in the conflict zone.
But Colombo said it had objected because she had wanted to "surreptitiously" pay floral tribute at Mullivaikkal, a lagoon area in the island's northern coast where Tamil Tiger leader Velupillai Prabhakaran was killed on May 18, 2009, in the war's final battle.
"It was pointed out by the Sri Lankan side...(to the UN) that if such a gesture needed to be made it should be done at a venue common to all victims of the terrorist conflict and not on the grounds where the Tiger leader met with his death," the statement said.
Pillay's mission took her to the former war zones of the country's north and east to meet relatives of those who disappeared during the decades-long conflict.
She later said that those who met with her were being visited by police and security forces and intimidated, a charge denied by Colombo.
Sri Lanka has resisted demands for what the UN calls "credible allegations" that up to 40,000 civilians were killed in the final months of the separatist war.
Colombo approved Pillay's visit after previously accusing her of overstepping her mandate. The U-turn came as Canada led calls for a boycott of a Commonwealth summit due to take place in Colombo in mid-November.
In March, the UN passed a resolution pressing Sri Lanka to more thoroughly investigate alleged war crimes.