Magnetic stand for electronic device