diff --git a/web/pgadmin/browser/static/js/panel.js b/web/pgadmin/browser/static/js/panel.js
index bf9e874ce..8c0fd3b03 100644
--- a/web/pgadmin/browser/static/js/panel.js
+++ b/web/pgadmin/browser/static/js/panel.js
@@ -97,6 +97,17 @@ define(
                 that.onCreate.apply(that, [myPanel, $container]);
               }
 
+              // Prevent browser from opening the drag file.
+              $('.pg-panel-content').bind('dragover', function (event) {
+                event.stopPropagation();
+                event.preventDefault();
+              });
+              $('.pg-panel-content').bind('drop', function (event) {
+                event.stopPropagation();
+                event.preventDefault();
+
+              });
+
               if (that.elContainer) {
                 myPanel.pgElContainer = $container;
                 $container.addClass('pg-el-container');
diff --git a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js
index b5503255c..4486832c2 100644
--- a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js
+++ b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js
@@ -491,6 +491,17 @@ define('tools.querytool', [
         }, 200);
       });
 
+      // Prevent browser from opening the drag file.
+      $('#datagrid').bind('dragover', function (event) {
+        event.stopPropagation();
+        event.preventDefault();
+      });
+      $('#datagrid').bind('drop', function (event) {
+        event.stopPropagation();
+        event.preventDefault();
+
+      });
+
       var open_new_tab = self.browser_preferences.new_browser_tab_open;
       if (_.isNull(open_new_tab) || _.isUndefined(open_new_tab) || !open_new_tab.includes('qt')) {
         // Listen on the panel closed event and notify user to save modifications.
