The invention belongs to the technical field of cameras, and particularly discloses a mobile phone camera. The camera includes a mobile phone shell body, a camera main body, a groove a rotating rod, agear, a rack, a moving rod, a guiding rod, a magnetic block, a spring one, a concave block, a pushing rod, a circular plate, a spring two and a circular groove. According to the camera, rotation of the camera main body drives rotation of the rotating rod, rotation of the rotating rod drives rotation of the gear, rotation of the gear drives moving of the rack, moving of the rack drives moving of the moving rod, and moving of the moving rod stretches the spring one; and when the camera main body is flipped by 180 degrees, the moving rod is attached to the magnetic block, the magnetic block adsorbs and fixes the moving rod, a protection function of the camera main body is achieved, the pushing rod is pushed, moving of the pushing rod drives moving of the concave block, the concave block moves to be attached to the moving rod, then the moving rod is pressed to be separated from the magnetic block, the moving rod moves to return to an original position under the action of elastic force ofthe spring one, moving of the moving rod drives moving of the rack, moving of the rack drives rotation of the sliding gear, and flipping of the camera main body is realized.