An electronic device connected to a head mounted device, the electronic device comprising: a display; a communication circuit; at least one processor electrically connected with the display and the communication circuit; and a memory electrically connected with the at least one processor, wherein the memory stores instructions that instruct the at least one processor to: receive a control signal from an external controller through the communication circuit, the control signal indicating an orientation of the external controller, identify a direction at which the external controller is oriented based on the received control signal, determine a first position (1741, 1941) in a virtual space displayed through the display, wherein the first position (1741, 1941) is in a designated first distance range away from a first reference position (1720, 1920) related to the external controller along the identified direction, wherein the first position is on a first line extending from the first reference position (1720, 1920) in the identified direction, and control the display to display a pointer at a second position (1741, 1951) on a second line extending from a second reference position (1710, 1910) corresponding to the position of the eyes of a user to or through the first position (1741, 1941), wherein the second position (1741, 1951) is in a designated second distance range away from the second reference position (1710, 1910); wherein a view angle at which the user views the first position (1741, 1941) from the second reference position (1710, 1910) differs from the identified direction at which the external controller is oriented. a display; a communication circuit; at least one processor electrically connected with the display and the communication circuit; and a memory electrically connected with the at least one processor, wherein the memory stores instructions that instruct the at least one processor to: receive a control signal from an external controller through the communication circuit, the control signal indicating an orientation of the external controller, identify a direction at which the external controller is oriented based on the received control signal, determine a first position (1741, 1941) in a virtual space displayed through the display, wherein the first position (1741, 1941) is in a designated first distance range away from a first reference position (1720, 1920) related to the external controller along the identified direction, receive a control signal from an external controller through the communication circuit, the control signal indicating an orientation of the external controller, identify a direction at which the external controller is oriented based on the received control signal, determine a first position (1741, 1941) in a virtual space displayed through the display, wherein the first position (1741, 1941) is in a designated first distance range away from a first reference position (1720, 1920) related to the external controller along the identified direction, wherein the first position is on a first line extending from the first reference position (1720, 1920) in the identified direction, and control the display to display a pointer at a second position (1741, 1951) on a second line extending from a second reference position (1710, 1910) corresponding to the position of the eyes of a user to or through the first position (1741, 1941), wherein the second position (1741, 1951) is in a designated second distance range away from the second reference position (1710, 1910); wherein a view angle at which the user views the first position (1741, 1941) from the second reference position (1710, 1910) differs from the identified direction at which the external controller is oriented.