BOSTON — The Massachusetts State Lottery has yielded more than $1 billion in annual profits, even as sales have dipped.

State Treasurer Deborah Goldberg said Monday that for the first time in its 45-year history the lottery topped $1 billion in estimated profits during the 2017 fiscal year, which ended June 30.

The haul eclipsed the FY16 total of $989 million.

Overall sales dipped from $5.23 billion in fiscal year 2016 to $5.09 billion in the 2017 fiscal year.

While sales of instant tickets dropped by about 2.7 percent from the 2016 fiscal year, KENO sales inched up.

All or Nothing, a new monitor game introduced early in FY17, generated an estimated $18.8 million in sales, up from the $2.2 million in FY16 sales of the game it replaced, Jackpot Poker.