Wells H. Thomsen, 65, retired director of the office of analysis and review in the Office of the Secretary of the Navy, died Feb. 29 at Alexandria Hospital after a heart attack.

He first came here in 1943 to serve as head of the Navy section of the Bureau of the Budget in the Executive Office. He transferred to the Office of the Secretary of the Navy in 1953. He retired five years ago.

Mr. Thomsen was born in Cleveland. A graduate of Oberlin College in Ohio, he received a master's degree in business and public administration from Harvard University, where he was a Littauer fellow.

He received the Navy Department's Distinguished Civilian Service Medal in 1962. He was given the Joslin Diabetes Foundation Award in 1977 for having been under insulin self-control for 50 years.

Since retiring, Mr. Thomsen, who lived in Alexandria, had been active in the Northridge Civic Association.

He is survived by his wife, Katherine B., of Alexandria; a daughter, Wendy H. Tell, of Columbus, Ohio; a brother, Mark L., of Palma de Mallorca, Spain, and three grandchildren.

The family suggests that expressions of sympathy be in the form of contributions to the American Diabetes Association.