An electric bed has a bed frame, multiple boards, and a motor structure. The bed frame comprises a lower bed frame and an upper bed frame, and the upper bed frame and the lower bed frame are connected by a connecting structure. The multiple boards are hinged, and at least one board is fixed onto the upper bed frame. The motor structure comprises a connecting rod, a slide bar, and a horizontal pushing motor system. The connecting rod has one end hinged with the first board of the multiple boards. The slide bar extends in the width direction of the bed frame and is arranged in a sliding chute in the length direction of the bed frame, so that it can slide along the length direction of the bed frame.