9:53 AM PT -- The Essex County Prosecutor's Office tells us Artie pled guilty to possession of 81 small bags of heroin worth $300-$500. In exchange, prosecutor's dismissed a possession of cocaine charge.
Artie Lange's life is at stake ... and that's why friends are getting him on a private jet to rehab after appearing in court Friday.
Artie's attorney, Frank Arleo, tells TMZ ... Artie pled guilty to possession of a controlled dangerous substance at a hearing in Essex County court in Newark, NJ. TMZ broke the story ... Artie was busted after missing a court date about his May drug arrest.
Artie is headed to an in-patient drug rehab program at an undisclosed location. Artie's set to be released from jail in a matter of hours and he'll hop on a private jet paid for by 2 comedian friends, who are rallying to save Artie's life.
The comedian's scheduled to be sentenced February 23.