Britney Spears had been on a 24-hour meth binge before she was rushed to the hospital, The NATIONAL ENQUIRER has learned exclusively.

Ironically, she was desperately trying to stay awake — because she was terrified that if she fell asleep, her family would “drag her off to a mental institution,” according to a close source.

The drama began at 2 a.m. Wednesday when Britney and Sam Lutfi checked into the Beverly Hills Hotel and she began doing meth.

In addition to her mental problems the ENQUIRER has learned that Britney is addicted to crystal meth, and details her addiction in a front page story this week.

Meanwhile, her meth habit played a key role in her recent hospitalization and friends told her mother, Lynne, that she hadn’t slept since last Saturday.

Her drug-taking went on all day, interrupted only by brief dashes to her home.

Secret arrangements for her hospitalization had been made — but no-one wanted it to happen at the hotel.

Finally, at 8 pm, photographer boyfriend Adnan Ghalib persuaded her to go home.

“The doctor came over but Britney was very spacey,” says a source.

“She was eerily quiet — when they called her name she wouldn’t even look at them. It was like she was deaf.

“A psychiatrist who came to examine her put the hospital plan into operation.”