How does the data from an APRS transmitter get to the Internet, e.g. to the aprs.to website?

This is done via so-called APRS gateways. Many radio amateurs operate a pure receive gateway. Other stations operate as digipeaters (relay stations) and transmit the data to an APRS-IS server at the same time.