Firefox on Fedora 39 refuses to play videos on YouTube and other sites and error displayed is often something that amounts to “unexpected error.”
You can solve this issue by installing
rpmfusion. You will need to enable the
--allowerasing flag to replace conflicting packages.
sudo dnf install ffmpeg --allowerasing -y
If you need more codecs, please see Fluendo - Codec Pack.