Skip to content

Open-source Python library for AI browser agents, plus Browser Use Cloud: stealth browsers and a hosted agent API.

add clipboard permissions at startup

Nick Sweeting7e9296e340c6
diff --git a/browser_use/browser/context.py b/browser_use/browser/context.py
index a073327f3..42817691a 100644
--- a/browser_use/browser/context.py
+++ b/browser_use/browser/context.py
@@ -498,6 +498,8 @@ class BrowserContext:
timezone_id=self.config.timezone_id,
)
+ await context.grant_permissions(['clipboard-read', 'clipboard-write', 'geolocation'])
+
if self.config.trace_path:
await context.tracing.start(screenshots=True, snapshots=True, sources=True)