I think halal mortgages are instructive on this point. To be clear, I’m not Muslim nor a lending expert, I just think it’s a really interesting setup.
As I understand it, sharia law forbids paying interest, so a conventional mortgage is not an option for adherents. However, several different mechanisms are allowed by which the purchaser gradually gains full ownership of the home. E.g. one is roughly equivalent to a rent-to-own agreement. The financier still gains a profit that reflects the risk their upfront investment is subject to.
What I find interesting is a recognition that some people need a lot of time to attain homeownership, and it may be valuable to let them live in the home before they fully achieve it, despite the outright rejection of lending as the mechanism.