A pickup winds its way up Casper Mountain on Dec. 26, 2014 in Casper, Wyo.. Wyoming, known more for its national parks, wildlife, recreation and energy production, ranked highly in Education Week’s state rankings of public education. (Alan Rogers/AP)

Education Week has come out with its annual state rankings for public education, and topping the list are plenty of the usual suspects, many of them in the Northeast. But also making its debut in the top 10 is a surprise: Wyoming, a state better known for its cowboys than its excellent schools.

Wyoming jumped from 23rd in the nation in 2013 to seventh this year, making it the only western state in the top echelon.

That doesn’t mean Wyoming students, whose overall academic performance is middling to slightly above average, made huge improvements. They didn’t.

The leap comes from a change in Ed Week’s ranking criteria. Instead of grading state education policies — traditionally a weak area for Wyoming — the magazine gave more weight to school funding and socioeconomic indicators like parent income and adult employment rates. Those are strong suits for a state with booming oil, gas and coal fields.

“Wyoming is in a part of the country where the economy has been strong, even through the recession, because of energy extraction industries,” said Chris Swanson, an Education Week vice president.

Wyoming’s rise is a reminder that state rankings, which are popular in the edu-world, should always be taken with a grain of salt. Who’s on top always depends on what’s being measured. But Wyoming’s rise also offers a glimpse of the state of public schools in a rural jurisdiction that is rarely mentioned in national education debates.

“The national discussion to a large extent will focus on what’s going on in the policy realm, whether there’s political drama going on, and it’s not a real prominent policy state and there’s not a lot of drama out there,” Swanson said. “That being said, Wyoming has an interesting story.”

Wyoming’s energy industries have helped fill its coffers, and it is now the third-highest education spender in the nation. The state spends about $17,758 per student each year, 50 percent higher than the national average of $11,735, and it spreads those dollars fairly equitably among students in poverty and their affluent peers, according to Ed Week’s analysis.

Wyoming residents also have relatively strong job prospects, according to the analysis. Fewer Wyoming children live in poverty — and more Wyoming children have at least one full-time working parent — than the national average.

Jillian Balow, the state’s newly elected state superintendent, said that the strong economy has been a boon for serving at-risk students. The gap between poor and affluent students in Wyoming is significant but far smaller than the national average, according to national test data.

“We have opportunities to make a difference in Wyoming with some of these factors in our favor,” Barlow said.

Massachusetts was the top-ranked state this year, unseating Maryland, which had held that spot since 2009. Maryland fell to third, behind New Jersey. Virginia fell from 4th to 12th. D.C.’s schools — which are hard to compare to states because the District is entirely urban — rose slightly to 38th.

The top 15 in Ed Week’s rankings, followed by the state scores. The U.S. average was a score of 74.3:

1. Massachusetts (86.2)

2. New Jersey (85.5)

3. Maryland (85.2)

4. Vermont (83.0)

5. New Hampshire (82.4)

6. Connecticut (82.3)

7. Wyoming (80.6)

8. Pennsylvania (80.1)

9. New York (80.0)

10. Minnesota (79.9)

11. Wisconsin (78.9)

12. Virginia (78.7)

13. Rhode Island (78.5)

14. Maine (77.1)

15. Delaware (76.7)