Charles, who has the title Duke of Rothesay while in Scotland, met volunteers, staff and patients at Clan Cancer Support in Aberdeen.
He was greeted by Lord Provost of Aberdeen George Adam and Aberdeen City Council chief executive Valerie Watts.
The charity offers free comfort, support and information to anyone affected by cancer. Set up in 1983, it celebrated 30 years on September 25.
Charles met volunteers at the centre's drop-in area and chatted with Clan Cancer's hairdresser before touring the library.
Charles, who wore a kilt of Stewart Hunting Ancient tartan, spoke with patients receiving complementary therapies and observed a relaxation session.
He later unveiled a plaque to mark his visit.
He said: "I'm thrilled to be able to come here today and see this absolutely remarkable place for the first time, but also to help celebrate the 30th anniversary.
"If it wasn't for the marvellous people who have the foresight and determination to get somewhere like this off the ground, I don't know where we would be."