Unfortunately, the demo will only last five in-game days, which is equivalent to roughly 100 minutes of gameplay. Granted, this if you installed the game from the official source, Minecraft.net.
However, if you installed it from elsewhere and after five in-game days you are still able to play, it is possible you might have gotten what is known as a ‘cracked’ version, which is essentially a pirated copy of the game. Please note that if you do have cracked Minecraft, approach with caution as it was illegally obtained (i.e. against the law).
Also, it’s nice to support the developers too, so I highly recommend you purchase the game once the demo is over or playing cracked.