Breaking it down to the molecular level, earning affiliate commissions requires that people click on your unique URLs and purchase products. This can be accomplished in a variety of different ways which include a website, a blog, a third party ecommerce platform (such as eBay) and so many others. No, you do not absolutely need to have a website to earn affiliate commissions. However, how do you intend to create visibility around your chosen products and affiliate network(s) without a website?
There are various ways to get sales, apart from a website.
The key thing is to provide a platform, where you will post
your affiliate links, so that visitors can click on them. This includes:
Email marketing - Send emails
You can post affiliate links on your YouTube videos
Write ebooks and include affiliate links there