A connector comprising: a housing that includes a lock section for locking to a mating connector so as to prevent disengagement of the mating connector, and guide walls on each of two side surfaces of the housing which two side surfaces face in directions opposite to each other, each of two first lock depression sections and each of two second lock depression sections being provided on each of the pair of guide walls; a contact for making contact with a contact of the mating connector; and slide members provided on both side surfaces and that are slidable with respect to the housing, the slide members sandwiched to be guided by the guide walls and having lock projection sections to project towards the guide walls, each slide member arranged to be slid in a first direction to be locked to the housing at a first position where the slide member is slid in the first direction, the first direction being the direction of locking the connector to the mating connector, the slide member being in the state in which the lock projection sections are locked to the first lock depression sections, the slide member arranged to hold the lock section in a state of being locked to the mating connector at the first position, a tip section of the slide member being positioned under a tip of the lock section to lift up a lock claw provided at the tip of the lock section, each slide member arranged to be slid in a second direction to be locked to the housing at a second position where the slide member is slid in the second direction, the second direction being the direction of pulling out the connector from the mating connector, the locking of the first lock depression sections to the lock projection sections being released, and the lock projection sections becoming locked to the second lock depression sections, the slide member arranged in the second position to hold the lock section in a state of being released from the locked state to the mating connector, the tip section of the slide member being positioned away from the tip of the lock section in the second direction so that the lock claw provided at the tip of the lock section is released from being lifted up. a housing that includes a lock section for locking to a mating connector so as to prevent disengagement of the mating connector, and guide walls on each of two side surfaces of the housing which two side surfaces face in directions opposite to each other, each of two first lock depression sections and each of two second lock depression sections being provided on each of the pair of guide walls; a contact for making contact with a contact of the mating connector; and slide members provided on both side surfaces and that are slidable with respect to the housing, the slide members sandwiched to be guided by the guide walls and having lock projection sections to project towards the guide walls, each slide member arranged to be slid in a first direction to be locked to the housing at a first position where the slide member is slid in the first direction, the first direction being the direction of locking the connector to the mating connector, the slide member being in the state in which the lock projection sections are locked to the first lock depression sections, the slide member arranged to hold the lock section in a state of being locked to the mating connector at the first position, a tip section of the slide member being positioned under a tip of the lock section to lift up a lock claw provided at the tip of the lock section, each slide member arranged to be slid in a second direction to be locked to the housing at a second position where the slide member is slid in the second direction, the second direction being the direction of pulling out the connector from the mating connector, the locking of the first lock depression sections to the lock projection sections being released, and the lock projection sections becoming locked to the second lock depression sections, the slide member arranged in the second position to hold the lock section in a state of being released from the locked state to the mating connector, the tip section of the slide member being positioned away from the tip of the lock section in the second direction so that the lock claw provided at the tip of the lock section is released from being lifted up.