The way I understand VPN is that all my data is routed through a remote server. So if I request data from site A, anyone monitoring data will see the data go to the remote server and not myself. If I then use my everyday Google account on site B, they will be able to identify me based on past login locations. So if I were using both sites A and B at the same time, is there any way for data from site A to be linked to me via my login details on site B?
In other words, when the VPN server receives data it needs to be able to identify who the data is for. So is there an identifying 'tag' in the data that could link my traffic from site A to my traffic from site B where I am logged in and therefore know that I have been visiting site A?
Yes and no. Lets say your VPN is compromised and there is a MITM (Man-In-The-Middle-Attack) going on. In this case the attacker could easily where the data is going from and where it is going to. If the attacker gets hold of the packets at the end of the VPN then he would need more information about the data itself (your login details, location and so on) to make a connection between the VPN data and your requests to understand where you are. TLDR: If nobody got hold of your VPN-Login or is able to interceipt the data then no, nobody will know where you are coming from.
What goerk27 said. VPN's encryption is end-to-end, so unless the hacker is on the other end, there's now way your ID gets compromised. Then VPNs of today also come equipped with dns and ip leak protections and a killswitch - ivacy, express and pure being some examples i can think of - in which case, the connection totally drops if the vpn gets disconnected, so you're pretty much safe.
Hey, if you are using a good vpn then you need not worry about this matter. Because it encrypts all your activities and has features like kill switch and DNS to protect for the duration you are working over the internet. Unless you have an ip leak or the vpn you are connected is not upto the mark, you can't be sure. I have been using express vpn and have never faced any problems as such.
What sarahgad said is pretty accurate. You need to make sure you are using a high quality vpn because it will have the kill switch and DNS features to protect you. So make sure you do your research, compare and contrast features, prices, etc. This will help you sort through the bad ones and find a good one that does what you want it to do.