The French president found himself under siege when his mobile phone number was published online after a journalist friend, who had it stolen during a robbery.
The burglar took full advantage of the theft by posting the mobile telephone number on an undisclosed website.
Subsequently, Mr. Macron, who has two iPhones, soon found himself being hounded by calls as well as dozens of text messages, some of them "unflattering."
At least one of them was also of a threatening nature, according to a minister cited by business magazine Challenges, who broke the story.
An official at the Elysee presidential palace later confirmed the president's number had been changed while security services made contact with the author of the disturbing text.
The official insisted the compromised phone had been an unsecured line used occasionally by Mr. Macron to communicate with people outside government.
He has another encrypted telephone he uses to liaise with members of his cabinet, often in late night calls and messages on Telegram and WhatsApp.