Peter the Great's primary reason for starting the Great Northern War was to gain for Russia permanent access to the Baltic.
When Peter became Tsar in 1682, Russia's only means of access by ship to the rest of the world was the port of Archangel, which was frozen over more than half the year and a long way from the Russian heartland. As a young man, Peter had acquired a love of ships and sailing (even learning how to build ships himself), and was determined to make Russia into a significant maritime power.
Other than Archangel, Russia had essentially two ways out into the world's oceans: north through the Baltic, or south through the Black Sea, the Dardanelles and the Mediterranean. During Peter's reign, the Ottoman Empire was much too powerful for Russia to confront (after the Battle of Poltava, in fact, Peter would fall into Ottoman hands and be forced to yield what little progress he had made in the southern direction). The northern route for Russia was blocked by the fact that the Baltic was essentially a Swedish lake. So this meant war with Sweden, a risk Peter was willing to take because he (very inaccurately) calculated that the young Swedish king Charles XII would be an easy opponent.
Source: Robert K. Massie's Peter the Great: His Life and World