Short answer: No, open source licensing does not prevent you from selling a product.
In this example, you'd be selling a service, not a software. The service you'd be selling would be the hosting of the software, and any data the consumer would create/store through your service.
Personally, I'd recommend thinking that one through properly, as you'd be held accountable for customer data and the security needed therein, reasonable availability (read uptime) and a bunch of other things. You'd be subject to so many various laws, including consumer rights laws in any country that is able to access and purchase the service. I.e., even if you're US based, if you make the service available for EU consumers, you'd have to deal with GDPR.
As for the "open source" aspect, there's a few things to unpack. This is technically a "terms of use", a license set by the copyright holder (usually the creator), which you're free to set for the software itself. "Open source" implies that anyone can distribute the code, make modifications or even sell software that includes the code, a definition set by the Open Source Initiative (a US based corporation, not a law-making entity). By itself, the term "open source" means nothing in the sense of defined law, and you're free to set whatever terms you want for whatever software you wish to develop. I.e., if you wish to make the source public for inspection and available for private use (but not commercial), you're not "open source" by OSIs definition.
With that said, publicly available source code (not using an open source/permissive license) is subject to theft and is a different pitfalls with its own legal issues. It's similar to placing a chair and table on your lawn - people can look at it, but they're not allowed to take it to their own lawn.