It has value largely because a lot of people think it has value. Like other commodities, currencies and tradable stuff, if people are willing to pay for it, then it has value. If people are willing to accept it as payment, then it can be used to transfer value. If people are willing to buy and keep it, then it can be used as a store of value.
For now most people tend to treat bitcoin like a gold but a version of high return .
They even know that bitcoin may worth nothing at some point , but they insist to get in and there you go .. the value created in the community and it's getting bigger and bigger.
The real value of bitcoin might be 0 and might be unlimited that nobody can imagined it. That's the charm of bitcoin to have real value.