Four police officers have died in a knife attack carried out by an administrator at the Paris police headquarters, according to a French police union official.

The attacker was shot to death.

Union official Loic Travers said the attack on Thursday appears to have begun in an office and continued elsewhere inside the large compound across the street from Notre Dame Cathedral.

Mr Travers said the motive was unknown, but the employee allegedly responsible for the violence apparently never posed any problems before.

He said he cannot remember an attack on police officers of this magnitude.