Oscar Fay Grimes, 98, a retired farmer and lifelong resident of Anne Arundel County, died Thursday at Anne Arundel General Hospital following a heart attack.

Mr. Grimes was born in Edgewater, Md., where he grew up and worked on his father's farm. The family later moved to another farm. In 1927, Mr. Grimes bought the Hill-Dale farm in Davidsonville. He remained there until he retired in 1962. Mr. Grimes then returned to Edgewater, where he lived until his death.

He was a director of his local branches of the Farm Bureau and the Soil Conservation Service. In 1952, he was awarded a certificate of merit in agriculture from the University of Maryland.

Mr. Grimes was a member of the Davidsonville United Methodist Church, where he served as a Sunday school teacher and board member for many years.

He was married three times. His first wife, the former Hattie Nutwell, died shortly after their marriage. His second wife and mother of their five children, the former Henrietta L. Glover, died in 1956. His third wife, the former Jennie Richardson, died in 1970.

Survivors include two sons, J. Grover, of Silver Spring, Oscar F. Jr., of Davidsonville; three daughters, Margaret G. Shepherd of Lothian, and Helen G. Duckett and Estelle G. Hall, both of Annapolis; a sister, Madeline Forthman of Oklahoma, 15 grandchildren and 14 great-grandchildren.

The family suggests that expressions of sympathy be in the form of contributions to the Davidsonville United Methodist Church Memorial Fund.