Thomas F. B. Hagan, 59, a former public relations director for the old Shoreham Hotel who later worked in the publishing business in New York City, died Friday at his home in New York after a heart attack.

After graduating from George Washington University in 1947, Mr. Hagan was the personal representative of Alfred Jonniaux, a former Belgian court painter who maintained a Washington studio for a number of years. Mr. Hagan also worked for the Shoreham Hotel as publicity director during the 1950s.

He then returned to his native New York City, where he was vice president of the Groiler Corp., a publishing company. In recent years, he had established his own company in New York, which supplied educational materials to individual members of the Armed Forces.

He graduated from the U.S. Maritime Academy at Great Neck, N.Y., and served aboard the fleet oiler U.S.S. Neosho during World War II.

Mr. Hagan, who maintained a home in Washington since the early 1950s, also had published a local magazine called "Pavillon" for several years during the 1950s.

Survivors include his mother, Mary Baskerville Gilman; a brother, William R., and a sister, Alice Jensen, all of Danbury, Conn.; another brother, George J., of Melvern L.I., N.Y.; two other sisters, Frances Panzarino of Brooklyn, and Virginia Donnelly of Forest Hills, N.Y., and two half-brothers, Robert Gilman of Long Island, N.Y., and Andrew Gilman of New York City.