you have multiple options, that are depending on your use case.
Use Eclipse Paho JavaScript to directly connect to the MQTT broker from within the web browser. I have done a similar use case as you descirbe at EclipseCon Europe. A Java client publishes random data and the web page shows a temperature gauge and other charts. Code and slides are available here.
Let your MQTT broker save all publishes to a database (see best practises). For getting the data to the browser I would recommend a REST API. With this option you can easily show historic data.
Hope that answers your question.
Cheers, Chris