Retired Rear Adm. W. Earl Gallaher, 75, who won the Navy Cross as a carrier pilot in the Battle of Midway in World War II and who was a staff officer in the Korean War, died of cancer Feb. 4 at Bethesda Naval Hospital. He lived in Kensington.

During the early days of the war, Adm. Gallaher, then a lieutenant, flew Dauntless dive bombers from the carrier Enterprise, which took part in most of the great carrier battles of the war.

At Midway, which was fought from June 3 to June 5, 1942, he commanded one of two Dauntless squadrons from the Enterprise that attacked Adm. Chuichi Nagumo's striking force. While Lt. Cmdr. Clarence W. McClusky's squadron crippled the carrier Kaga, Lt. Gallaher's squadron mortally wounded Nagumo's flagship, the carrier Akagi.

In his official Navy history of World War II, Adm. Samuel Eliot Morison said that the Dauntless attacks ended a period of about 100 seconds in which the Japanese "were certain they had won the Battle of Midway, and the war. This was their high tide of victory." The Dauntless forays, he said, brought about "a complete reversal of fortune."

Adm. Gallaher was awarded the Navy Cross, that service's highest decoration for valor except for the Medal of Honor, for "leading his squadron in vigorous and intensive dive-bombing attacks against the Japanese invasion fleet. He defied a concentrated barrage of antiaircraft fire and powerful fighter opposition with cool skill and complete disregard for his own safety."

Later, he served aboard an escort carrier in the battles for the Philippines and Okinawa. After the war, he was on the staff of the Naval War College. He earned the Legion of Merit while serving as assistant chief of staff of Far East Naval forces during the Korean War.

From 1955 to 1957, he commanded the carrier Princeton and then was a liaison officer to the Supreme Allied Commander, Atlantic. He retired in 1959 and at that time was promoted to rear admiral on the basis of his war record.

Adm. Gallaher was born in Wilmington, Del. He was a 1931 graduate of the U.S. Naval Academy at Annapolis, and earned his wings in 1935.

He was a member of the Retired Officers Association and the Disabled American Veterans.

Survivors include his wife, the former Caro Miller, of Kensington; a son, Albert, of Novato, Calif., and a sister, Elizabeth Sharman of Wilmington.