Some DPI stats first:
Mack Book Pro 13.3" has 227 DPI(2560x1600px/13.3 inches).
iPhone 6s has 326 DPI(750x1334px/4.7 inches).
Sony Xperia Z tablet has 224 DPI(1920x1200px/10.10 inches).
However when I save JPEG image for web it has 72 DPI and the image looks good only if I set container resolution 2 times lower then the image resolution.
For example,
<img src="200x200px_72dpi_image.jpg" width="100px" height="100px">
produces good results for retina displays(iPhone 6s, Mac Book Pro 13.3", etc.) and
<img src="100x100px_72dpi_image.jpg" width="100px" height="100px">
produces bad results.
What can I do with that in 2018? Should 300 DPI image be used for web?