Addressing mourners at a solemn funeral ceremony at the Invalides military museum in Paris, Macron compared Arnaud Beltrame's sacrifice to those of France's World War II heroes and said his example would “remain etched in French hearts”.
Lieutenant-Colonel Arnaud Beltrame, 44, was the fourth and final victim in the shooting spree last Friday in the southwestern towns of Carcassonne and nearby Trebes. Beltrame was stabbed and shot after offering himself in exchange for a hostage.
In a speech in front of Beltrame's family, hundreds of gendarmes, members of the government and public who had gathered to pay respects, Macron paid a glowing tribute to the man who has quickly become a national hero.
“At the moment of the final goodbye I offer you the recognition, the admiration and the affection of the whole country,” said Macron.
The president also said that “while the name of his murderer is already being forgotten, the name of Arnaud Beltrame will always represent French heroism.”
And speaking about the terror threat facing France Macron said: “This is a new test. But our people have overcome many others. And for that reason we will overcome this one. We will win thanks to the resilience and calm of the French people and by the cohesion of a united country.”
The senior policeman had taken the place of a woman held as a final hostage in a supermarket by 25-year-old gunman Radouane Lakdim, who pledged allegiance to the Islamic State group.
France has lost more than 240 lives to jihadists over the past three years, and the attack is the country's worst since Macron became president last May.
Around 200 of Beltrame's colleagues from the gendarmerie, a national police force which is part of the military, will attend the ceremony in Paris from 1030 GMT.
Macron gave the eulogy at Les Invalides, a historic complex which is home to France's army museum and a veterans' retirement centre.
Across the country, police stations paused for a minute's silence at 0800 GMT.
The coffin of Beltrame, who was married, was flown in from Carcassonne on Tuesday, draped in the French flag with his military cap laid upon it.
Along with the police officer, Lakdim shot dead the passenger of a car he hijacked in Carcassonne and two people in the supermarket he had besieged in Trebes.
Beltrame took the place of the woman Lakdim was using as a human shield, hoping to negotiate once the terrified shoppers and supermarket staff were out of the way.
But Lakdim shot Beltrame and slit his throat, leading police to intervene and shoot the attacker dead.
The attacker wounded four other people, including the driver of the hijacked car and a policeman shot while out jogging.
Beltrame has been hailed as a national hero, with family members saying it was typical of him to put others first.
“You behaved in your last moments just as you behaved throughout your whole life: as a patriot, as a good man, as a man with a big heart,” his brother Damien wrote on Facebook.