Episodes of cabin fever are depicted in books and movies as a type of madness caused by isolation, usually ending in some kind of gruesome scene. In reality, cabin fever is essentially a response to being stuck inside a confined indoor area for a prolonged period of time. Someone cooped up might become restless, irritable, and anxious, but will usually come around once someone suggests playing a board game or cards—or, in more extreme cases, when the rescue party arrives.
Bertha Muzzy Bower wrote about it in an eponymous Western novel. The book's title provides us with an early record of the term used in print, and its narrative gives an insight into the condition.
"Cabin Fever," by B.M. Bower, is a new story of the West just issued by Little, Brown & Co. There is a certain malady of mind induced by too much monotony: fashionable folk call it ennui, but Westerns call it "cabin fever." But whenever it attacks you it reveals the things hidden in your soul; it uncovers your secret weaknesses and unsuspected virtues. It descended on Bud Moore, irritated by months of inaction, surfeited with the "small beer" of prosaic domestic life after carefree independence, and bothered by noncomprehension of the same symptoms in his hitherto pleasing wife, Marie. A sharp exchange of compliments, a quarrel fostered by a greedy mother-in-law, and Bud's domestic happiness lay in ruins. Freed of wife and child and bank account, he launched forth to reconstruct his life.
— The Times Dispatch (Richmond, Virginia), 13 Jan. 1918
While cabin fever isn't officially classified as a medical condition, it is closely related to seasonal affective disorder (SAD), a state of depression that tends to recur chiefly during the late fall and winter and is associated with shorter hours of daylight.