Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

If an HTTP request is sent from an iframe, where does the iframed site see the request from?

Suppose I make a webpage that includes

<iframe src="http://google.com"/>

and a user browses through that iframe. Does Google see the request made from the server I'm hosting my site on, or from the user's router?


1 Answers

You do NOT load content of iframe source from your server. You just pass that code to the user browser then everything happens on client side. Therefore google will see client ip address and etc.

When one website is called through another domain whether iframe or not, browsers send current domain name to the next target (google.com in your case) with HTTP Referrer data. This is the only way of google.com to understand where the client request google from.

Details : What is the HTTP Referer if the link is clicked in an <iframe>?

like image 74
Mehmet Ince Avatar answered Dec 31 '25 16:12

Mehmet Ince



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!