The number of South Dakota farms declined 6 percent during a five-year span between 2012 and 2017, according to a new report.

The United States Department of Agriculture says there were 29,968 South Dakota farms in 2017 compared to 31,989 in 2012. The USDA's National Agricultural Statistics Service released the 2017 Census of Agriculture on Thursday.

The report says land in farms in 2017 was at 43.2 million acres, down about 1 percent from 2012. The average size farm in South Dakota was 1,443 acres, up 7 percent.

The total value of agricultural products sold in 2017 was $9.7 billion, down 4 percent. Of the total value of production, 47 percent originated from livestock and 53 percent from crops. Average net income per farm was $81,763, down 20 percent from 2012.

In 2017, the average age of producers was 56.2 years, and the number of young producers - defined as age 35 or younger - was 5,717. In South Dakota, 81 percent of farms have internet access, compared to 75 percent of all U.S. farms.