Betamax was superior recording format over VHS due to resolution (250 lines vs. 240 lines), slightly superior sound, and a more stable image. Betamax recorders were also of higher quality construction which meant that the gear stuck around.
This made it ideal for media companies and home users who could afford to pay for better quality. However VHS had an early victory by being universally adopted by the porn industry. It was then effectively pushed by the video rental industry.
However although it was killed off on the consumer market there was a small market for BetaMax in the media business.
So despite pulling Betamax machines from the market in 2002 Sony could still flog Betamax tapes to these guys and find a ready market.
Now Sony has decided that this market is just announced it'll stop selling them from March of next year.
The last Betamax products in production were the EL-500B, 2L-500MHGB, 2L-750MHGB cassettes and L-25CLP cleaning tape.
Still cudos to Sony for stubbornly supporting a market which it lost a long time ago. If you have a Betamax machine lying around you better stock up on some tapes in the next few months before they run out completely.