How do you value the stock options of a company that hasn’t had its IPO?
You can value a company by comparing it to its peers (this is like company Y which has similar users, growth potential etc)
You can value a company by only caring about its assets and liabilities.
Private shares of a company can exist and be traded, another market based valuation just with fewer data points that are private and not publicly shared.
And plenty more ways. Finance is really all about answering this question, how much is something worth and then creating mechanisms to trade that value in different ways.