TMZ has learned the plan to get Britney into UCLA Medical Center had been hatched for days -- it was aborted last night, but executed just minutes ago.

Back at her house, Britney's psychiatrist told her she was going to the hospital. Her response was, "Is something wrong?" She was not resistant. She made hot chocolate and waited before paramedics arrived and placed her on a gurney.

We're told the psychiatrist felt her condition had deteriorated. Britney had not slept since Saturday -- a day and half longer than she stayed up in recent memory.

The reason she's at UCLA is her new treating psychiatrist practices out of that medical center.

We're told during her initial 72-hour stay she cannot be forced to take medication against her will. If, however, she refuses to take meds, the plan is for the the psych to go to court and have Britney held for an additional 14 days, during which time she can administer proper medications.

And get this ironic twist -- Lynne Spears and Adnan drove to the Medical Center in the same car. A source tells us when Lynne found out Britney was being committed, she blamed it on Sam and was extremely agitated. When Brit heard that, she screamed to her mother, "Shut the hell up."

