Here's an article about it:
https://www.forbes.com/sites/kanzahmaktoum/2024/11/07/f1-drivers-draw-a-line-whats-behind-the-fias-swearing-crackdown/
It's to make the sport more appealing for American media guidelines, mainly ESPN. On American broadcast television, you may never hear any S-words or F-words, but watch long enough and you're bound to see things that are a whole lot worse.