The U.S. economy grew at a faster rate in the third quarter than previously estimated, climbing at its fastest rate in nearly two years.

The economy grew 3.5 percent, according to new estimates released Thursday by the Commerce Department, boosted by increased spending by consumers and exports.

Thursday’s estimate was the third and final for the quarter from the Commerce Department, which previously estimated the economy grew just 3.2 percent over that time frame.

ADVERTISEMENT

The fairly strong growth in the third quarter came after nearly a year of subpar growth for the U.S. economy. The nation’s gross domestic product grew by just 1.4 percent in the second quarter of the year and 1.1 percent in the first three months of the year.

But the strong gains over the course of the year set the stage for President Obama — whose eight years in office were dominated by the economy and digging out of a recession that hit before his first election — to close out on a strong note.