Patrick Byrne — the controversial ex-CEO of Overstock — sold all his shares this week.

Byrne — who left the discount furniture seller in a cloud of controversy after confessing to a romantic relationship with a Russian spy — said he sold all of his 10-plus percent stake in Overstock — thanks to the company’s short sellers.

In a filing after the market closed Wednesday, Byrne said he sold 4.7 million shares between Monday and Wednesday for a little under $100 million.

In a blog post, he rattled on about a government conspiracy to help the company’s short sellers as the reason for the sale.

“The proximate cause … came when we heard over the weekend that starting last Friday, the Deep State’s pets at the SEC began leaking something to their clients JPMorgan, Morgan Stanley, and Goldman,” Byrne said on his blog.

“They leaked that they were going to Bazoomba [destroy] our digital dividend. Once that started getting back to me, I realized this: Whenever I have had any question about whether the SEC would or would not do something totally outrageous in order to hurt our company to benefit their clients on Wall Street, they never let me down: they always did the evil thing.”

As The Post reported Tuesday, Byrne had put the company’s short sellers in a bind before banks like JPMorgan and Morgan Stanley came to the rescue.

As a result, the stock pop Byrne helped create in recent weeks has deflated — just in time for him to sell.

Overstock’s shares closed down more than 8%, to $16.19 a share on Wednesday. That’s on top of a 40% drop from mid-day Friday through Tuesday.