Ryan Donovan, 22, Dartford, Kent, spoke only to confirm his name, age and address during the short hearing at Southampton Magistrates’ Court.
Donovan has been charged with killing Lt. Commander Ian Molyneux, 36, who was fatally shot on board HMS Astute while it was docked in Southampton on Friday.
He has also been charged with the attempted murders of Petty Officer Christopher Brown, 36, Chief Petty Officer David McCoy, 37, and Lt. Commander Christopher Hodge, 45.
Donovan was remanded in custody to appear at Winchester Crown Court on April 13, the Press Association reported.
The shootings took place as local dignitaries, including the city council’s mayor, chief executive and leader, were being given a tour of the submarine while it was on a five-day official visit to the city.
Royston Smith, a local council leader on board and a former Royal Air Force engineer disarmed the shooter.
Police and the defense ministry have said the shooting was not terrorism-related and there was no risk to the public.
