Activity › Forums › Salesforce® Discussions › How can i make a callout(automatically) on VF page load? Salesforce® Discussions How can i make a callout(automatically) on VF page load? Posted by Suraj on April 24, 2017 at 12:38 PM How can i make a callout(automatically) on VF page load? Manpreet replied 9 years, 1 month ago 2 Members · 1 Reply 1 Reply Manpreet Member May 22, 2017 at 6:23 AM Hi suraj, Method 1: <script type = “text/javascript”> window.onload=function() { alert(“Hi”); }; </script> Method 2: Visuaforce page: <apex:page action=”{!onLoad}”> </apex:page> Controller: public class sample { public sample(){ } public void onLoad(){ ……………… ……………… } } Thanks. Log In to reply. Public All Members My Connections Only Me PublicAll MembersMy ConnectionsOnly Me Public All Members My Connections Only Me