js – detecting retina displays June 23, 2011February 16, 2013 by Tom it’s simple :) if (window.devicePixelRatio >= 2) { alert('retina found'); };