shortest path first algorithm A routing algorithm that iterates on length of path to determine a shortest-path spanning tree. Commonly used in link-state routing algorithms. Sometimes called the Dijkstra algorithm. See also link state routing algorithm.