Lindsay Lohan

Lindsay Lohan pleaded not guilty to grand theft in Los Angeles Superior Court Wednesday.

The 24-year-old actress appeared in court to plead not guilty to the charge, which is a felony. Lohan's probation, stemming back to 2009, was revoked and bail was set at $40,000. She posted bail shortly after the arraignment, according to E! Online.

D.A.: Lindsay Lohan to be charged with grand theft

The charge stems from an allegation that the Mean Girls actress stole a $2,500 necklace from a Venice, Calif., store on Jan. 22, nearly three weeks after she was released from court-ordered rehab.

"You need to follow the laws like everybody else," Judge Keith Schwartz told Lohan in court. "You're no different than anyone else so please, don't push your luck." Schwartz warned the actress that should she break any other laws, she would be sent back to jail with no bail.

Lindsay Lohan's attorney says actress didn't steal necklace

According to the judge, Lohan's attorney, Shawn Chapman Holley, is hoping to settle with the district attorney's office. She is due back in court on Feb. 23.

If convicted, she faces up to three years in state prison.