A winning lottery ticket sold in Oregon meant a lucky $6.4 million jackpot — even though the ticket owner lives in Iraq and bought the ticket through an online service, it was reported Wednesday.

It’s the first time in the Oregon Lottery’s history that a person living overseas bought a Megabucks ticket online and struck it rich, NBC affiliate KTVZ reported.

The Iraqi, whose name is not being released, purchased the lottery ticket through the website theLotter.com, a company that sends people to buy lottery tickets for customers and charges a fee, officials told the station.

The company has a London mailing address, but said it has 20 offices around the world.

The ticket was purchased in Bend, Oregon on Aug. 24, and the ticketholder claimed the prize in person on Dec. 1, KTVZ reported.

"This is absolutely unprecedented for the Oregon Lottery” Oregon Lottery spokesman Chuck Baumann told the station. He said lottery officials consulted with legal experts who told them the online sale appears to be legal.

The Iraqi chose to take the jackpot over 20 years, rather than taking a lump-sum payment that would have cut his winnings by half, the station reported. The first payment of $256,000 was made last week.

"I was surprised," said Judy Bell-Putis, the owner of the store that sold the winning ticket. The store will get a $64,000 prize for selling the winner.