There are a couple of reasons. First, Albany had a long history as an administrative center stretching back to colonial times. The English maintained the original Dutch settlement there because it was the location where they conducted diplomatic meetings with the Iroquois who were still quite powerful up through the American Revolution. It was also important that Albany sat on the Hudson River and was near the mouth of the Mohawk River, meaning that most of the settled territory of the state could reach Albany by boat up to a time. Pragmatically, Albany made more sense to have as the state capital because it is more centrally located to the rest of the state than New York City. When Albany was made the capital in 1797, it was expected that settlement would continue to expand North and West. Having the capital closer to the "frontier" was seen as a way to expedite the process and increase efficiency for the future.