Go step by step and test.
1. Power off the router. Unplug it from the wall. Wait a while.
Plug it back in. Power the router on. Wait until all lights are lit properly. It will take a while.
Restart the computer.
Start up in Safe Mode. This will remove some system caches.
https://support.apple.com/en-us/HT201262
Once in Safe Mode, launch Safari and test the websites.
Click the “Restart” button at the bottom to exit Safe Mode.
Launch Safari holding the shift key down. This will startSafari in Safe Mode
2. Remove cookies related to websites and test.
“Remove stored cookies and data: Click Manage Website Data,
select one or more websites, then click Remove or Remove All.”
https://support.apple.com/en-us/HT204098
3 Clear history and test
https://support.apple.com/guide/safari/clear-your-browshttps://etrecheck.com/maspro
4. If this doesn’t help, download EtreCheck: https://etrecheck.com/maspro and post the report here.
Click, “Free Download” button and then “Click to download” button,
open Downloads folder, click on it to open, and then select ”Open”.
Click on the bouncing EtreCheck icon in the Dock.
“Choose a problem” from the popup menu box, and then “Start EtreCheck” in the dialog.
Click “Share Report” button in the toolbar and select “Copy report” .
Paste the report when you reply.
Note: This is a diagnostic test. Reading the report will help us not make unnecessary suggestions.