This is something that keeps me worried at night. Unlike other historical artefacts like pottery, vellum writing, or stone tablets, information on the Internet can just blink into nonexistence when the server hosting it goes offline. This makes it difficult for future anthropologists who want to study our history and document the different Internet epochs. For my part, I always try to send any news article I see to an archival site (like archive.ph) to help collectively preserve our present so it can still be seen by others in the future.
Actually I think TIFF or Adobe DNG are the lossless formats for photos.
TIFF is a classic storage format, but PNG is common for web images and isn’t going away either. DNG is for RAW sensor output from professional cameras and is not used for edited and published images. However if you’re archiving your photo collection or something than keep the DNGs!