“To be off one’s rocker” is a common idiomatic expression in English to mean to be crazy, insane or out of one’s mind. A rocker (besides being someone who likes to play rock music) is the curved piece of wood on the bottom of a rocking chair that allows it to move backward and forward.
However, the origin of the expression has nothing to do with the rocking chair! The expression first appeared in print around 1896 at about the same time as the expression, “to be off one’s trolley.” Both expressions have the same meaning. These two expressions became popular at a time when electric streetcars were being installed in major American cities.
The wheel or runner above the streetcar that makes contact with the electrical line is called either a rocker or a trolley! Sometimes due to a technical or driver error, this rocker/trolley would lose contact with the wires causing the streetcar to no longer get electricity rendering it inoperative.