How can we compare the internet and social media to the Panopticon?

I assume that you are referring to Jeremy Bentham's idea of the Panopticon design for a prison. If so, the internet and social media resemble the Panopticon in that they allow others to be watching over us at all times.

The idea of the Panopticon was that it would be structured so that a guard could be watching every prisoner at any point in time. The prisoners were potentially under constant surveillance. You can argue that the internet is like this. Every move we make online (and even, in some ways, in the physical world) can be observed when we use the internet. This is particularly true when we post things about our lives on social media.

In these ways, we are voluntarily putting ourselves in a Panopticon when we use the internet and social media.