iPados Unable to read from the browser's clipboard. Please make sure you have granted access for this website to read from the clipboard.
Is there an existing issue for this?
- [x] I have searched the existing issues
OS/Web Information
- Web Browser: safari
- Local OS: ipados18.2, ios18.2
- Remote OS: rocky linux 9.5
- Remote Architecture: local script install
code-server --version: 4.96.2 08cbdfbdf11925e8a14ee03de97b942bba7e8a94 with Code 1.96.2
Steps to Reproduce
- pwa or use safari open code-server with https
- input string in edit code area
Expected
Unable to read from the browser's clipboard. Please make sure you have granted access for this website to read from the clipboard.
Actual
Unable to read from the browser's clipboard. Please make sure you have granted access for this website to read from the clipboard.
Logs
Screenshot/Video
No response
Does this bug reproduce in native VS Code?
Yes, this is also broken in native VS Code
Does this bug reproduce in GitHub Codespaces?
Yes, this is also broken in GitHub Codespaces
Are you accessing code-server over a secure context?
- [ ] I am using a secure context.
Notes
No response
Thanks for the report! If this is also broken in Codespaces we should submit the issue upstream (https://github.com/microsoft/vscode) so they can fix it.
https://github.com/microsoft/vscode/issues/141704 seems related
I found the issue because we used the AI extension. ai require clipboard context to analysis.
Hi @code-asher, when I use vscode.dev or github.dev (Codespaces) on my iPad, I don't see the clipboard error I get with code-server (exactly the same as @joewen85 above). Are we convinced this issue also exists upstream?
Could we maybe reopen this issue to investigate? I'm happy to help with more evidence or however I can. This error window appearing at every keystroke is incredibly annoying :-(
Hi @code-asher, when I use vscode.dev or github.dev (Codespaces) on my iPad, I don't see the clipboard error I get with code-server (exactly the same as @joewen85 above). Are we convinced this issue also exists upstream?
Could we maybe reopen this issue to investigate? I'm happy to help with more evidence or however I can. This error window appearing at every keystroke is incredibly annoying :-(
this problem on lingma-alibaba plugin.
Hi @code-asher, when I use vscode.dev or github.dev (Codespaces) on my iPad, I don't see the clipboard error I get with code-server (exactly the same as @joewen85 above). Are we convinced this issue also exists upstream? Could we maybe reopen this issue to investigate? I'm happy to help with more evidence or however I can. This error window appearing at every keystroke is incredibly annoying :-(
this problem on lingma-alibaba plugin.
I don't have this plugin and I see the exact same problem. For context:
code-server: v4.103.2 Code: 1.103.2 Commit: 3c5deac16d0b3620cce8abca637012904ea6520e Date: 2025-08-25T17:36:40.017Z Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/26.0 Safari/605.1.15 Extensions: ESLint, Gemini Code Assist, vscode-icons, YAML
Yup we can reopen, I am not sure how it could be on our end though, we are not patching anything related to the clipboard (other than a cli command we added to put something in the clipboard, but this seems unrelated).
Any idea if it reproduces when you use code serve-web?
@guiruggiero Just to check, you are using code-server with https right? And do you access it directly, or is it in an iframe or anything like that? Does it happen with no plugins installed?
I'm experiencing the same issue with two code-server instances, both having SSL. On my iPadOS 18.3, it keeps throwing an error "Unable to read from the browser's clipboard". I've tried using it via Blink as well, but the issue persists. One server is running version 4.103.2, and the other is running version 4.104.3. I have used this setup before and it worked. Specifically, my problem is with the extension Continue.dev, and now I'm unsure if the issue is with the extension or the code-server. The problem occurs when using autocomplete with the continue.dev extension.
I am getting this on ChromeOS too with code-server running in the local VM. Clipboard access does show as granted in Chrome settings for the site.
Error in the DevTools console is:
notificationsAlerts.ts:42 Unable to read from the browser's clipboard. Please make sure you have granted access for this website to read from the clipboard.
c @ notificationsAlerts.ts:42
(anonymous) @ notificationsAlerts.ts:28
C @ event.ts:1201
D @ event.ts:1212
fire @ event.ts:1236
addNotification @ notifications.ts:228
notify @ notificationService.ts:234
prompt @ notificationService.ts:312
(anonymous) @ clipboardService.ts:60
readText @ clipboardService.ts:56
await in readText
$readText @ mainThreadClipboard.ts:26
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
C @ event.ts:1201
fire @ event.ts:1232
fire @ ipc.net.ts:652
A @ ipc.net.ts:1022
(anonymous) @ ipc.net.ts:962
C @ event.ts:1201
fire @ event.ts:1232
acceptChunk @ ipc.net.ts:394
(anonymous) @ ipc.net.ts:350
(anonymous) @ browserSocketFactory.ts:231
C @ event.ts:1201
fire @ event.ts:1232
Yhn.j.onload @ browserSocketFactory.ts:92
FileReader
t @ browserSocketFactory.ts:105
Yhn.s @ browserSocketFactory.ts:111
notificationsAlerts.ts:42 Unable to read from the browser's clipboard. Please make sure you have granted access for this website to read from the clipboard.
c @ notificationsAlerts.ts:42
(anonymous) @ notificationsAlerts.ts:28
C @ event.ts:1201
D @ event.ts:1212
fire @ event.ts:1236
addNotification @ notifications.ts:228
notify @ notificationService.ts:234
prompt @ notificationService.ts:312
(anonymous) @ clipboardService.ts:60
readText @ clipboardService.ts:56
await in readText
$readText @ mainThreadClipboard.ts:26
S @ rpcProtocol.ts:458
Q @ rpcProtocol.ts:443
M @ rpcProtocol.ts:373
L @ rpcProtocol.ts:299
(anonymous) @ rpcProtocol.ts:161
C @ event.ts:1201
fire @ event.ts:1232
fire @ ipc.net.ts:652
A @ ipc.net.ts:1022
(anonymous) @ ipc.net.ts:962
C @ event.ts:1201
fire @ event.ts:1232
acceptChunk @ ipc.net.ts:394
(anonymous) @ ipc.net.ts:350
(anonymous) @ browserSocketFactory.ts:231
C @ event.ts:1201
fire @ event.ts:1232
Yhn.j.onload @ browserSocketFactory.ts:92
FileReader
t @ browserSocketFactory.ts:105
Yhn.s @ browserSocketFactory.ts:111
ChromeOS: 142.0.7444.40 code-server: v4.104.3 Code: 1.104.3 Commit: cd40509fbbc684c5e9b566d9cb027f6ee9df36a6 Date: 2025-10-03T18:52:07.792Z (3 wks ago) Browser: Mozilla/5.0 (X11; CrOS x86_64 14541.0.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36
Just installing the latest version to see if it still occurs.
Are you using an iframe or accessing directly? Any chance you can run code serve-web with native VS Code in your VM and see if it reproduces there as well?
I tried to reproduce with code-server 4.105.1 and chromium 141.0.7390.54, copy/paste with both keybindings and the context menu (after accepting a prompt to use the clipboard) are working for me. I tried copying and pasting both within code-server and to/from external applications.
Maybe this is somehow specific to ChromeOS or iOS. 🤔
We have reproduced this issue in the iframe. Direct access works normally: the browser will display a popup window to request permission. However, there is no such permission request popup window in the iframe, so it is impossible to copy (content/data).
We have reproduced this issue in the iframe. Direct access works normally: the browser will display a popup window to request permission. However, there is no such permission request popup window in the iframe, so it is impossible to copy (content/data).
solved by
Now that I've updated to v4.105.1 I have not seen this issue again.