How to GIF (2025 Edition)
11 comments
·February 6, 2025autoexec
areyourllySorry
i don't understand how one thing leads to another. if anything, a popular feature (videos) is more protected against 0days as there's more eyes on it, not the opposite. what else could a "malicious video file" be, a cognitohazard? i am aware of the facebook tails video 0day but that's not a browser issue, nor is it a common issue
lxe
Unless I can right click (or long press) and copy or save and then paste somewhere else, I don't want it.
ghxst
Are the features and codecs safari doesn't support part of WebKit? If so does that mean that any browser on iOS doesn't support it either?
Also, the article links to a blog post[0] about video with transparency, and although the performance is the main complaint I had no idea this was a thing! Worth the read if you enjoyed the article I think.
koakuma-chan
Every browser on iOS is WebKit unless you're from EU.
ghxst
Yeah that's my point, but I'm not sure if codec support is implemented outside of that.
koakuma-chan
Nope, it's implemented in the browser engine. I honestly find it funny that, for example, Opera, Edge and Chrome are supposedly different browsers, even though it's all actually Chromium and there is no meaningful difference.
asimpletune
Basically use webp if you want to have the fewest problems while still retaining the majority of benefits out there. Good compression, works across most devices, and unexpected pitfalls like animating transparency aren't an issue.
vbernat
The article is surprisingly inconclusive. From my understanding, the easiest way is to use the <video> tag with mp4.
asimpletune
<video> and mp4 can also work well. As a GIF replacement, the initial differences are minor because you can easily add loop and autoplay to the video’s attributes, and both work with most browsers’ reader modes. From my tests, though, video-as-GIFs isn't a feature supported by the major RSS readers, while WebP works without any issues.
Anyways, the real insurmountable problem is animations with transparent backgrounds. There’s no good way to do this in mp4, and WebP seems to be the only format that does it well. But because of all the little pains, headaches, and surprises that can arise due to subtly different use cases, I still think WebP is the format that will give you the most benefit with the least drawbacks for silent animated images. Even without having transparent backgrounds as a requirement.
seqizz
I re-encoded all of my webm's to mp4's back then on my "gif blog", thanks to Safari and all my mac-using friends saying "I can't see it". Now look who started to support it eh.
Replacing gifs with video files does come with an increased the risk of malware being spread. If it gets common to stuff webpages full of video files we should expect to see an increase in the use of malicious video files to do bad things.
In my case, as someone who doesn't allow javascript by default and prevents media from playing automatically the only image on that entire page that loaded for me was dancingbaby.webp
Everything else (if it showed up at all) displayed as generic blocked elements I'd have to click on to view (or right click to download) so if that catches on websites that are currently busy with gifs should load a lot faster and look a lot cleaner. That's a plus.