Actor Sam Lloyd, best known for playing lawyer Ted Buckland in Scrubs, has been diagnosed with cancer.

A GoFundMe page set up by his family said that in January, shortly after the 55-year-old actor and his wife Vanessa welcomed their first child, a boy called Weston, he began to experience headaches.

Lloyd also lost 10 pounds but assumed this was due to the stress of being a new father.

In mid January, he attended doctors and had a CT scan which revealed "a mass" on his brain, requiring brain surgery the next day.

The surgeon was unable to remove the tumour, and he was informed that the cancer in his brain had metastasized from his lungs.

Further scans showed the cancer was also in his liver, spine, and jaw.

Scrubs creator Bill Lawrence tweeted a link to the fundraising campaign and wrote: "This is Sam. He was Ted on Scrubs. He's a pal. Just had his first baby. Get involved if you can. I am."

Actor Zach Braff, who played Dr. John 'J.D.' Dorian in Scrubs, replied to Lawrence, saying: "Tragic news from our beloved Sam (aka, Ted the Lawyer). I will of course be getting involved. Please send him your love."

The GoFundMe for the actor has so far raised $67,838 of a $100,000 goal.