Because they were losing traffic to chatGPT. Stack Overflow has been all about numbers and revenue for some time now.
> Here is how platforms die: first, they are good to their users; then they abuse their users to make things better for their business customers; finally, they abuse those business customers to claw back all the value for themselves. Then, they die.
[1] https://pluralistic.net/2023/01/21/potemkin-ai/#hey-guys