I'm not an expert in multimedia codecs or patents so I leave the actual decision to people who know better (maybe legal team in WMF?) but according to tech news, major patents for mp4 have already expired and the rest will expire soon, a large batch of them expired in November 2023 and a major batch will expire by March this year.
There are many types of mp4, I think H.263 is now expired but again, not an expert.
VP9 and H.264 are not expired yet (but H.264 seems to be expiring soon so maybe we should prepare?):