An antenna structure comprising: a metal housing, the metal housing comprising a front frame, a backboard, and a side frame, the side frame being positioned between the front frame and the backboard; the side frame defining a slot, the front frame defines a first gap and a second gap, the first gap communicating with a first end of the slot and extending to cut across the front frame; the second gap communicating with a second end of the slot and extending to cut across the front frame; the metal housing being divided into at least a first portion by the slot, the first gap, and the second gap; a first feed source, the first feed source electrically connected to the first portion for supplying current to the first portion; a first ground portion, the first ground portion electrically connected to the first portion for grounding the first portion; and a first switching circuit, one end of the first switching circuit electrically connected to the first portion and another end of the first switching circuit being grounded; wherein the side frame comprises an end portion, a first side portion, and a second side portion, the first side portion and the second side portion are respectively connected to two ends of the end portion, the end portion, the first side portion, and the second side portion all connect to the front frame and the backboard, the slot is at least defined at the end portion, is adjacent to the backboard and extends to an edge of the front frame; wherein the antenna structure further comprises a first electronic element positioned in a receiving space adjacent to the first side portion and a radiator, the radiator is positioned adjacent to the first gap and is spaced apart from the first electronic element, the radiator is positioned adjacent to the first electronic element and the first side portion, and extends along a direction parallel to the end portion towards the second side portion until the radiator passes over the first electronic element and further extends along a direction parallel to the end portion towards the second side portion. a metal housing, the metal housing comprising a front frame, a backboard, and a side frame, the side frame being positioned between the front frame and the backboard; the side frame defining a slot, the front frame defines a first gap and a second gap, the first gap communicating with a first end of the slot and extending to cut across the front frame; the second gap communicating with a second end of the slot and extending to cut across the front frame; the metal housing being divided into at least a first portion by the slot, the first gap, and the second gap; a first feed source, the first feed source electrically connected to the first portion for supplying current to the first portion; a first ground portion, the first ground portion electrically connected to the first portion for grounding the first portion; and a first switching circuit, one end of the first switching circuit electrically connected to the first portion and another end of the first switching circuit being grounded; wherein the side frame comprises an end portion, a first side portion, and a second side portion, the first side portion and the second side portion are respectively connected to two ends of the end portion, the end portion, the first side portion, and the second side portion all connect to the front frame and the backboard, the slot is at least defined at the end portion, is adjacent to the backboard and extends to an edge of the front frame; wherein the antenna structure further comprises a first electronic element positioned in a receiving space adjacent to the first side portion and a radiator, the radiator is positioned adjacent to the first gap and is spaced apart from the first electronic element, the radiator is positioned adjacent to the first electronic element and the first side portion, and extends along a direction parallel to the end portion towards the second side portion until the radiator passes over the first electronic element and further extends along a direction parallel to the end portion towards the second side portion.