Skip to content
Related Articles
Get the best out of our app
GeeksforGeeks App
Open App

Related Articles

HTML | DOM Location reload() Method

Improve Article
Save Article
Like Article
Improve Article
Save Article
Like Article

The location reload() method in HTML DOM is used to reload the current document. This method refreshes the current documents. It is similar to the refresh button in the browser. 


location.reload( forceGet )

Parameters: This method contains single parameter forceGet which is optional. This parameter contains boolean value which are listed below:

  • True: Reloads the current page from the server.
  • False: Reloads the current from the cache.

Return Value: It does not return any value. 



<!DOCTYPE html>
            HTML DOM Location reload() Method
        <!--script to reload current page-->
            function locationreload() {
            HTML DOM Location reload() Method
            Click on the button to reload the document
        <!-- script call here -->
        <button onclick = "locationreload()">
            Reload page


Before click on the button:


After click on the button: The document will reload. 

Supported Browsers: The browser supported by DOM Location reload() Method are listed below:

  • Google Chrome 1
  • Edge 12
  • Internet Explorer 5.5
  • Firefox 1
  • Opera 3
  • Safari 1

My Personal Notes arrow_drop_up
Last Updated : 05 Jul, 2022
Like Article
Save Article
Similar Reads
Related Tutorials