Commander is a rank used by the service organizations of many civilizations. On Earth, this rank has a history dating back to at least the 18th century to wind-powered seagoing navies, and has equivalents used by numerous species and cultures on several planets.
The rank of Commander is a senior rank, common among executive officers and senior department heads. Naval tradition states that even if a naval vessel is commanded by an officer whose rank is commander or lieutenant commander, that officer is still referred to as a captain while on the deck of their own vessel.
In the Xindi-Reptilian military of the 22nd century, some commanders controlled a squadron and a regiment.
The rank of commander in the Romulan Star Empire is considered the equivalent of a Starfleet captain. Also, a subcommander grade exists in the Romulan military, with this rank also used in the 22nd century by the Vulcan High Command.
The 23rd century Imperial Klingon Fleet used the rank of commander to denote the commanders of smaller space vessels, such as a Bird-of-Prey. A Klingon rank of captain was used for larger vessels with this title carrying over to the 24th century Klingon Defense Force.