Links can have a substantial impact on rankings, but not always. Contextual links, inbound links, and internal links are or are most likely ranking factors. Nofollow, paid, and outbound links are unlikely (or definitely not) a ranking signal. (There’s an entire section discussing links as ranking factors starting on page 361 of Google Ranking Factors: Fact or Fiction.)