This expression is believed to have originated from horse racing, where a wire was hung up over the finish line to help determine a winner. Thus, races that were extremely close could be described as "coming down to the wire," quite literally. Read more about it here . These days we use this idiom when an outcome is unknown until the very last millisecond.